KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mmbase > module > core > ByteFieldContainer


1 /*
2
3 This software is OSI Certified Open Source Software.
4 OSI Certified is a certification mark of the Open Source Initiative.
5
6 The license (Mozilla version 1.0) can be read at the MMBase site.
7 See http://www.MMBase.org/license
8
9 */

10 package org.mmbase.module.core;
11
12 /**
13  * MMObjectNodes can contain Binary data. These BYTE fields can be
14  * retrieved, byt the node does not store them internally - nodes are cached, and
15  * caching large amounts of binary data is bad for performance.
16  * However, some classes keep a separate cache for binaries (i.e. Images).
17  * This class is meant to hold byte arrays while simultaneously keep data as to
18  * which object it is part of. This allows for caching and passing binary values
19  * between functions without loosing track of which image it is part of.
20  *
21  * @author Pierre van Rooden
22  * @version $Id: ByteFieldContainer.java,v 1.4 2005/10/02 16:30:00 michiel Exp $
23  * @since MMBase-1.7
24  * @deprecated
25  */

26 public class ByteFieldContainer {
27     public int number = -1;
28     public byte[] value = null;
29
30
31     /**
32      * Constructor of this container class.
33      * @param number The node number of the node where the byte[] is belonging to, or -1 if the byte array is not yet associated with a node.
34      * @param value The byte array which this container is wrapping.
35      */

36     public ByteFieldContainer(int number, byte[] value) {
37         this.number = number;
38         this.value = value;
39     }
40
41 }
42
Popular Tags