public class MarcXchangeEventConsumer extends java.lang.Object implements javax.xml.stream.util.XMLEventConsumer, MarcXchangeConstants, MarcListener
BIBLIOGRAPHIC_TYPE, CODE_ATTRIBUTE, COLLECTION, CONTROLFIELD, DATAFIELD, FORMAT_ATTRIBUTE, HOLDINGS_TYPE, IND_ATTRIBUTE, LEADER, MARC21_FORMAT, MARC21_SCHEMA_LOCATION, MARC21_SCHEMA_URI, MARCXCHANGE_FORMAT, MARCXCHANGE_V1_NS_URI, MARCXCHANGE_V2_0_SCHEMA_LOCATION, MARCXCHANGE_V2_NS_URI, RECORD, SUBFIELD, TAG_ATTRIBUTE, TYPE_ATTRIBUTE
Constructor and Description |
---|
MarcXchangeEventConsumer() |
Modifier and Type | Method and Description |
---|---|
void |
add(javax.xml.stream.events.XMLEvent event) |
MarcXchangeEventConsumer |
addNamespace(java.lang.String uri) |
void |
beginCollection()
Begin of a record collection.
|
void |
beginRecord(java.lang.String format,
java.lang.String type)
Begin of a record.
|
void |
endCollection()
End of a collection.
|
void |
endRecord()
End of a record.
|
void |
field(MarcField marcField)
A field.
|
java.lang.String |
getFormat() |
java.lang.String |
getType() |
void |
leader(java.lang.String label)
The leader (or label) of a record.
|
MarcXchangeEventConsumer |
setFormat(java.lang.String format) |
MarcXchangeEventConsumer |
setMarcListener(MarcListener listener) |
MarcXchangeEventConsumer |
setMarcListener(java.lang.String type,
MarcListener listener) |
MarcXchangeEventConsumer |
setMarcValueTransformers(MarcValueTransformers marcValueTransformers) |
MarcXchangeEventConsumer |
setType(java.lang.String type) |
public MarcXchangeEventConsumer setMarcListener(java.lang.String type, MarcListener listener)
public MarcXchangeEventConsumer setMarcListener(MarcListener listener)
public MarcXchangeEventConsumer addNamespace(java.lang.String uri)
public MarcXchangeEventConsumer setMarcValueTransformers(MarcValueTransformers marcValueTransformers)
public void beginCollection()
MarcListener
beginCollection
in interface MarcListener
public void endCollection()
MarcListener
endCollection
in interface MarcListener
public void beginRecord(java.lang.String format, java.lang.String type)
MarcListener
beginRecord
in interface MarcListener
format
- the record formattype
- the record typepublic void endRecord()
MarcListener
endRecord
in interface MarcListener
public void leader(java.lang.String label)
MarcListener
leader
in interface MarcListener
label
- the labelpublic void field(MarcField marcField)
MarcListener
field
in interface MarcListener
marcField
- the field.public void add(javax.xml.stream.events.XMLEvent event) throws javax.xml.stream.XMLStreamException
add
in interface javax.xml.stream.util.XMLEventConsumer
javax.xml.stream.XMLStreamException
public java.lang.String getFormat()
public MarcXchangeEventConsumer setFormat(java.lang.String format)
public java.lang.String getType()
public MarcXchangeEventConsumer setType(java.lang.String type)