Class Catalog
- java.lang.Object
-
- org.glassfish.contextpropagation.wireadapters.Catalog
-
- All Implemented Interfaces:
Serializable
public class Catalog extends Object implements Serializable
Contains metadata that identifies the each context entry on a stream. This information helps recover from an unrecoverable IO error when reading context-propagation data from a stream. It makes it possible to skip a corrupted context.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
CATALOG_KEY
static String
CATALOG_META_KEY
-
Constructor Summary
Constructors Constructor Description Catalog()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(short position)
boolean
equals(Object obj)
short
getStart()
int
hashCode()
void
prepareToRead()
void
read(ObjectInputStream is)
void
setMeta(long meta)
void
setPosisionsFrom(Catalog catalog)
boolean
skipToNextItem(ObjectInputStream ois)
String
toString()
void
updateCatalogMetadata(byte[] contents)
void
upItemNumber(int delta)
void
write(ObjectOutputStream os)
-
-
-
Field Detail
-
CATALOG_KEY
public static final String CATALOG_KEY
- See Also:
- Constant Field Values
-
CATALOG_META_KEY
public static final String CATALOG_META_KEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
add
public void add(short position)
-
upItemNumber
public void upItemNumber(int delta)
-
prepareToRead
public void prepareToRead()
-
skipToNextItem
public boolean skipToNextItem(ObjectInputStream ois) throws IOException
- Throws:
IOException
-
write
public void write(ObjectOutputStream os) throws IOException
- Throws:
IOException
-
read
public void read(ObjectInputStream is) throws IOException
- Throws:
IOException
-
updateCatalogMetadata
public void updateCatalogMetadata(byte[] contents)
-
setMeta
public void setMeta(long meta)
-
setPosisionsFrom
public void setPosisionsFrom(Catalog catalog)
-
getStart
public short getStart()
-
-