diff --git a/regxmllib/src/main/java/com/sandflow/smpte/klv/KLVInputStream.java b/regxmllib/src/main/java/com/sandflow/smpte/klv/KLVInputStream.java index 6dec729..37b4b1c 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/klv/KLVInputStream.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/klv/KLVInputStream.java @@ -40,6 +40,9 @@ */ public class KLVInputStream extends InputStream implements DataInput { + /** + * Possible byte ordering of a KLV packet + */ public enum ByteOrder { LITTLE_ENDIAN, BIG_ENDIAN diff --git a/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/KLVException.java b/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/KLVException.java index e3f2d62..899b5d9 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/KLVException.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/KLVException.java @@ -25,6 +25,9 @@ */ package com.sandflow.smpte.klv.exceptions; +/** + * Exceptions raised when processing KLV packets + */ public class KLVException extends Exception { public static String MAX_LENGTH_EXCEEED = "Maximum in-memory KLV size exceeded."; diff --git a/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/TripletLengthException.java b/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/TripletLengthException.java index 61514b5..1e47846 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/TripletLengthException.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/klv/exceptions/TripletLengthException.java @@ -26,6 +26,9 @@ package com.sandflow.smpte.klv.exceptions; +/** + * Raised when the length of a KLV triplet is not valid + */ public class TripletLengthException extends RuntimeException { public TripletLengthException() { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/mxf/RandomIndexPack.java b/regxmllib/src/main/java/com/sandflow/smpte/mxf/RandomIndexPack.java index c05eebd..ed18f6a 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/mxf/RandomIndexPack.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/mxf/RandomIndexPack.java @@ -88,13 +88,19 @@ public static RandomIndexPack fromTriplet(Triplet triplet) throws KLVException { return pp; } + /** + * @return Ordered array containing the offsets stored in the RIP + */ public ArrayList getOffsets() { return offsets; } private final ArrayList offsets = new ArrayList<>(); - static public class PartitionOffset { + /** + * Represents one partition offset entry stored in the RIP + */ + static public class PartitionOffset { private final long bodySID; private final long offset; @@ -103,10 +109,18 @@ public PartitionOffset(long bodySID, long offset) { this.offset = offset; } + /** + * + * @return Identifies the partition + */ public long getBodySID() { return bodySID; } + /** + * + * @return Offset (in bytes) of the partition + */ public long getOffset() { return offset; } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/register/QualifiedSymbol.java b/regxmllib/src/main/java/com/sandflow/smpte/register/QualifiedSymbol.java index b866522..4e4630e 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/register/QualifiedSymbol.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/register/QualifiedSymbol.java @@ -46,10 +46,17 @@ public QualifiedSymbol(String symbol, URI namespace) { this.namespace = namespace; } + /** + * @return Namespace component of the Qualified Symbol + */ public String getSymbol() { return symbol; } + /** + * + * @return Namespace component of the Qualified Symbol + */ public URI getNamespace() { return namespace; } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/DuplicateEntryException.java b/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/DuplicateEntryException.java index 7c30d0b..797c05f 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/DuplicateEntryException.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/DuplicateEntryException.java @@ -26,8 +26,7 @@ package com.sandflow.smpte.register.exceptions; /** - * - * @author Pierre-Anthony Lemieux (pal@sandflow.com) + * Raised when two entries have identical ULs and/or symbols */ public class DuplicateEntryException extends Exception { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/InvalidEntryException.java b/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/InvalidEntryException.java index 27a579c..e8366cb 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/InvalidEntryException.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/register/exceptions/InvalidEntryException.java @@ -26,8 +26,7 @@ package com.sandflow.smpte.register.exceptions; /** - * - * @author Pierre-Anthony Lemieux (pal@sandflow.com) + * Raised when an entry is not valid */ public class InvalidEntryException extends Exception { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/FragmentBuilder.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/FragmentBuilder.java index b1c1c93..5cc8046 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/FragmentBuilder.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/FragmentBuilder.java @@ -87,6 +87,9 @@ */ public class FragmentBuilder { + /** + * Defines all events raised by this class + */ public static enum EventCodes { /** @@ -173,7 +176,10 @@ private EventCodes(Event.Severity severity) { } } - + + /** + * All events raised by this class are instances of this class + */ public static class FragmentEvent extends com.sandflow.util.events.BasicEvent { final String reason; @@ -287,8 +293,8 @@ public FragmentBuilder(DefinitionResolver defresolver, * Instantiates a FragmentBuilder * * @deprecated Replaced by - * {@link FragmentBuilder(DefinitionResolver, Map, - * AUIDNameResolver, EventHandler)}. This constructor does not allow the + * {@link #FragmentBuilder(com.sandflow.smpte.regxml.dict.DefinitionResolver, java.util.Map, com.sandflow.smpte.regxml.FragmentBuilder.AUIDNameResolver, com.sandflow.util.events.EventHandler)}. + * This constructor does not allow the * caller to provide an event handler, and instead uses java.util.logging to * output events. * @@ -332,8 +338,7 @@ public boolean handle(com.sandflow.util.events.Event evt) { * Instantiates a FragmentBuilder. * * @deprecated Replaced by - * {@link FragmentBuilder(DefinitionResolver, Map, - * AUIDNameResolver, EventHandler)}. This constructor does not allow the + * {@link #FragmentBuilder(com.sandflow.smpte.regxml.dict.DefinitionResolver, java.util.Map, com.sandflow.smpte.regxml.FragmentBuilder.AUIDNameResolver, com.sandflow.util.events.EventHandler) }. This constructor does not allow the * caller to provide an event handler, and instead uses java.util.logging to * output events. * diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/MXFFragmentBuilder.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/MXFFragmentBuilder.java index 83b9f73..443b030 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/MXFFragmentBuilder.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/MXFFragmentBuilder.java @@ -67,6 +67,9 @@ public class MXFFragmentBuilder { private static final UL PREFACE_KEY = UL.fromURN("urn:smpte:ul:060e2b34.027f0101.0d010101.01012f00"); + /** + * Defines all events raised by this class + */ public static enum EventCodes { /** @@ -97,7 +100,10 @@ private EventCodes(Event.Severity severity) { } } - + + /** + * All events raised by this class are instance of this class + */ public static class MXFEvent extends BasicEvent { public MXFEvent(EventCodes kind, String message) { @@ -130,8 +136,7 @@ static void handleEvent(EventHandler handler, com.sandflow.util.events.Event evt } /** - * @deprecated Replaced by {@link fromInputStreamfromInputStream(InputStream,DefinitionResolver, - * FragmentBuilder.AUIDNameResolver,UL,Document)}. This constructor does not allow the + * @deprecated Replaced by {@link #fromInputStream(java.io.InputStream, com.sandflow.smpte.regxml.dict.DefinitionResolver, com.sandflow.smpte.regxml.FragmentBuilder.AUIDNameResolver, com.sandflow.util.events.EventHandler, com.sandflow.smpte.util.UL, org.w3c.dom.Document) }. This constructor does not allow the * caller to provide an event handler, and instead uses java.util.logging to * output events. * @@ -160,8 +165,10 @@ public static DocumentFragment fromInputStream(InputStream mxfpartition, } /** - * @deprecated Replaced by {@link fromInputStreamfromInputStream(InputStream,DefinitionResolver, - * FragmentBuilder.AUIDNameResolver,UL,Document)}. This constructor does not allow the + * @deprecated Replaced by {@link #fromInputStream(java.io.InputStream, com.sandflow.smpte.regxml.dict.DefinitionResolver, + * com.sandflow.smpte.regxml.FragmentBuilder.AUIDNameResolver, com.sandflow.util.events.EventHandler, + * com.sandflow.smpte.util.UL, org.w3c.dom.Document)} + * This constructor does not allow the * caller to provide an event handler, and instead uses java.util.logging to * output events. * diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/XMLSchemaBuilder.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/XMLSchemaBuilder.java index 7cf486f..c206ca1 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/XMLSchemaBuilder.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/XMLSchemaBuilder.java @@ -99,6 +99,9 @@ public class XMLSchemaBuilder { private final NamespacePrefixMapper prefixes = new NamespacePrefixMapper(); private final EventHandler evthandler; + /** + * Defines the events returned by this class + */ public static enum EventCodes { /** @@ -114,6 +117,9 @@ private EventCodes(Event.Severity severity) { } + /** + * All events raised by this class are instances of this class. + */ public static class SchemaEvent extends BasicEvent { final String reason; @@ -189,7 +195,7 @@ public XMLSchemaBuilder(DefinitionResolver resolver, EventHandler handler) { * any metadictionary covered by the resolver. * * @deprecated Replaced by - * {@link XMLSchemaBuilder(DefinitionResolver resolver, EventHandler handler)} + * {@link #XMLSchemaBuilder(com.sandflow.smpte.regxml.dict.DefinitionResolver, com.sandflow.util.events.EventHandler) } * This constructor does not allow the caller to provide an event handler, * and instead uses java.util.logging to output events. * @@ -240,7 +246,6 @@ private String createQName(URI uri, String name) { * @throws com.sandflow.smpte.regxml.XMLSchemaBuilder.RuleException * @throws org.xml.sax.SAXException * @throws java.io.IOException - * @throws java.net.URISyntaxException */ public Document fromDictionary(MetaDictionary dict) throws ParserConfigurationException, KLVException, RuleException, SAXException, IOException { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/MetaDictionary.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/MetaDictionary.java index f8ac982..40ac7da 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/MetaDictionary.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/MetaDictionary.java @@ -243,14 +243,23 @@ public void add(Definition def) throws IllegalDefinitionException { this.definitions.add(def); } + /** + * @return SchemeID field of the MetaDictionay + */ public UUID getSchemeID() { return schemeID; } + /** + * @return SchemeURI field of the MetaDictionay + */ public URI getSchemeURI() { return schemeURI; } + /** + * @return Description field of the MetaDictionay + */ public String getDescription() { return description; } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/CharacterTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/CharacterTypeDefinition.java index fbd2ef8..68b0ebb 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/CharacterTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/CharacterTypeDefinition.java @@ -28,6 +28,9 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +/** + * Character Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class CharacterTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ClassDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ClassDefinition.java index ca1ee88..3128ef4 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ClassDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ClassDefinition.java @@ -33,6 +33,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Class Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class ClassDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/Definition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/Definition.java index 5026b28..ac3bca7 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/Definition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/Definition.java @@ -104,7 +104,6 @@ public void setName(String name) { * Supports the visitor design pattern. * @see DefinitionVisitor * @param visitor Visitor instance that will process the definition - * @throws com.sandflow.smpte.regxml.dict.definitions.DefinitionVisitor.VisitorException */ abstract public void accept(DefinitionVisitor visitor) throws DefinitionVisitor.VisitorException; diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/EnumerationTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/EnumerationTypeDefinition.java index a746a8e..866baff 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/EnumerationTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/EnumerationTypeDefinition.java @@ -42,11 +42,15 @@ import org.w3c.dom.Document; import static org.w3c.dom.Node.ELEMENT_NODE; +/** + * Enumeration Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class EnumerationTypeDefinition extends Definition { private static class EnumerationElementAdapter extends XmlAdapter> { + @Override public ArrayList unmarshal(Object v) throws Exception { ArrayList al = new ArrayList<>(); diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ExtendibleEnumerationTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ExtendibleEnumerationTypeDefinition.java index 3371de8..3bd2760 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ExtendibleEnumerationTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/ExtendibleEnumerationTypeDefinition.java @@ -34,6 +34,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Extendible Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class ExtendibleEnumerationTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FixedArrayTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FixedArrayTypeDefinition.java index 349e6ae..9ef4363 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FixedArrayTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FixedArrayTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Fixed Array Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class FixedArrayTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FloatTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FloatTypeDefinition.java index b9d1f8a..793dddd 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FloatTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/FloatTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlEnumValue; import javax.xml.bind.annotation.XmlType; +/** + * Float Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class FloatTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IndirectTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IndirectTypeDefinition.java index 36da395..71fa27d 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IndirectTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IndirectTypeDefinition.java @@ -28,6 +28,9 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +/** + * Indirect Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class IndirectTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IntegerTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IntegerTypeDefinition.java index 4eaa208..8136f4b 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IntegerTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/IntegerTypeDefinition.java @@ -31,6 +31,9 @@ import javax.xml.bind.annotation.XmlEnum; import javax.xml.bind.annotation.XmlEnumValue; +/** + * Integer Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class IntegerTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/LensSerialFloatTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/LensSerialFloatTypeDefinition.java index 840d746..ccf6912 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/LensSerialFloatTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/LensSerialFloatTypeDefinition.java @@ -29,7 +29,7 @@ import javax.xml.bind.annotation.XmlAccessorType; /** - * Corresponds to a type defined in RDD 18 and erroneously added to Class 13. + * Corresponds to a type defined in RDD 18. * @deprecated */ @XmlAccessorType(XmlAccessType.NONE) diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/OpaqueTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/OpaqueTypeDefinition.java index 070482c..fd0bb1d 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/OpaqueTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/OpaqueTypeDefinition.java @@ -28,6 +28,9 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +/** + * Opaque Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class OpaqueTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyAliasDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyAliasDefinition.java index c5499b4..1574061 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyAliasDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyAliasDefinition.java @@ -33,6 +33,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Property Alias Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class PropertyAliasDefinition extends PropertyDefinition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyDefinition.java index 0667cbe..409c36b 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/PropertyDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Property Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class PropertyDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RecordTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RecordTypeDefinition.java index e1ad290..222aaa0 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RecordTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RecordTypeDefinition.java @@ -41,6 +41,9 @@ import org.w3c.dom.Document; import static org.w3c.dom.Node.ELEMENT_NODE; +/** + * Record Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class RecordTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RenameTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RenameTypeDefinition.java index 2d01667..5d008ce 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RenameTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/RenameTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Rename Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class RenameTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/SetTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/SetTypeDefinition.java index 1687f7e..077e859 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/SetTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/SetTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Set Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class SetTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StreamTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StreamTypeDefinition.java index 982edfd..acf3a81 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StreamTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StreamTypeDefinition.java @@ -28,6 +28,9 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; +/** + * Stream Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class StreamTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StringTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StringTypeDefinition.java index 83c1e91..d4fffec 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StringTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StringTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * String Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class StringTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StrongReferenceTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StrongReferenceTypeDefinition.java index 0a734b8..de4ccea 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StrongReferenceTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/StrongReferenceTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Strong Reference Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class StrongReferenceTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/VariableArrayTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/VariableArrayTypeDefinition.java index 663bfaf..8d8ff5a 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/VariableArrayTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/VariableArrayTypeDefinition.java @@ -32,6 +32,9 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Variable Array Type Definition as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class VariableArrayTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/WeakReferenceTypeDefinition.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/WeakReferenceTypeDefinition.java index 99c45e1..d0f0921 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/WeakReferenceTypeDefinition.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/definitions/WeakReferenceTypeDefinition.java @@ -34,6 +34,9 @@ import javax.xml.bind.annotation.XmlElementWrapper; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; +/** + * Weak Reference Type as defined in ST 2001-1 + */ @XmlAccessorType(XmlAccessType.NONE) public class WeakReferenceTypeDefinition extends Definition { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/importers/RegisterImporter.java b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/importers/RegisterImporter.java index 378aa68..0b5141e 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/importers/RegisterImporter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/regxml/dict/importers/RegisterImporter.java @@ -70,6 +70,9 @@ public class RegisterImporter { private final static Logger LOGGER = Logger.getLogger(RegisterImporter.class.getName()); + /** + * Defines all events raised by the class + */ public static enum EventKind { /** @@ -109,6 +112,9 @@ private EventKind(Event.Severity severity) { } + /** + * All events raised by this class are instances of this class + */ public static class RegisterEvent extends com.sandflow.util.events.BasicEvent { public RegisterEvent(EventKind kind, String message) { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateDictionaryXMLSchema.java b/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateDictionaryXMLSchema.java index 28bbf3b..53c1fdf 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateDictionaryXMLSchema.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateDictionaryXMLSchema.java @@ -64,13 +64,16 @@ public class GenerateDictionaryXMLSchema { private final static Logger LOG = Logger.getLogger(GenerateDictionaryXMLSchema.class.getName()); - private final static String USAGE = "Generate XML Schema for RegXML Metadictionaries.\n" + protected final static String USAGE = "Generate XML Schema for RegXML Metadictionaries.\n" + " Usage:\n" + " GenerateDictionaryXMLSchema -d regxmldictionary1 regxmldictionary2 regxmldictionary3 ... -o outputdir\n" + " GenerateDictionaryXMLSchema -?\n"; private final static String XMLSCHEMA_NS = "http://www.w3.org/2001/XMLSchema"; + /** + * Usage is specified at {@link #USAGE} + */ public static void main(String[] args) throws IOException, EOFException, KLVException, ParserConfigurationException, JAXBException, FragmentBuilder.RuleException, TransformerException, IllegalDefinitionException, IllegalDictionaryException, Exception { if (args.length < 4 diff --git a/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateXMLSchemaDocuments.java b/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateXMLSchemaDocuments.java index d0f7fce..0f74517 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateXMLSchemaDocuments.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/tools/GenerateXMLSchemaDocuments.java @@ -52,10 +52,13 @@ */ public class GenerateXMLSchemaDocuments { - private final static String USAGE = "Generates XML Schema documents for JAXB-annotated classes.\n" + protected final static String USAGE = "Generates XML Schema documents for JAXB-annotated classes.\n" + " Usage: GenerateXMLSchemaDocuments -cp classpath -d outdir\n" + " GenerateXMLSchemaDocuments -?"; + /** + * Usage is specified at {@link #USAGE} + */ public static void main(String[] args) throws FileNotFoundException, JAXBException, IOException, InvalidEntryException, DuplicateEntryException, Exception { if (args.length != 4 || "-?".equals(args[0])) { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/tools/RegXMLDump.java b/regxmllib/src/main/java/com/sandflow/smpte/tools/RegXMLDump.java index d14dc2f..71c9377 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/tools/RegXMLDump.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/tools/RegXMLDump.java @@ -68,7 +68,7 @@ public class RegXMLDump { private static final UL PREFACE_KEY = UL.fromURN("urn:smpte:ul:060e2b34.027f0101.0d010101.01012f00"); - private final static String USAGE = "Dump header metadata of an MXF file as a RegXML structure.\n" + protected final static String USAGE = "Dump header metadata of an MXF file as a RegXML structure.\n" + " Usage:\n" + " RegXMLDump ( -all | -ed ) ( -header | -footer | -auto ) (-l labelsregister) -d regxmldictionary1 regxmldictionary2 regxmldictionary3 ... -i mxffile\n" + " RegXMLDump -?\n" @@ -81,12 +81,14 @@ public class RegXMLDump { + " -auto: dumps metadata from the footer partition if available and from the header if not\n"; private enum TargetPartition { - HEADER, FOOTER, AUTO } + /** + * Usage is specified at {@link #USAGE} + */ public static void main(String[] args) throws Exception { boolean error = false; diff --git a/regxmllib/src/main/java/com/sandflow/smpte/tools/XMLRegistersToDict.java b/regxmllib/src/main/java/com/sandflow/smpte/tools/XMLRegistersToDict.java index 0c6f238..3e7e703 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/tools/XMLRegistersToDict.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/tools/XMLRegistersToDict.java @@ -57,7 +57,7 @@ public class XMLRegistersToDict { private final static Logger LOG = Logger.getLogger(XMLRegistersToDict.class.getName()); - private final static String USAGE = "Converts XML Registers to RegXML metadictionary.\n" + protected final static String USAGE = "Converts XML Registers to RegXML metadictionary.\n" + " Usage: XMLRegistersToDict -e elementsregspath\n" + " -l labelsregpath\n" + " -g groupsregpath\n" @@ -65,6 +65,9 @@ public class XMLRegistersToDict { + " outputdir\n" + " XMLRegistersToDict -?"; + /** + * Usage is specified at {@link #USAGE} + */ public static void main(String[] args) throws FileNotFoundException, JAXBException, IOException, InvalidEntryException, DuplicateEntryException, Exception { if (args.length != 9 || "-?".equals(args[0]) diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/ExcelCSVParser.java b/regxmllib/src/main/java/com/sandflow/smpte/util/ExcelCSVParser.java index b3f5259..47a1a69 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/ExcelCSVParser.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/ExcelCSVParser.java @@ -37,6 +37,9 @@ public class ExcelCSVParser { Reader reader; + /** + * Indicates an error has been encountered when parsing a CSV file + */ public static class SyntaxException extends Exception { } private enum State { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/HalfFloat.java b/regxmllib/src/main/java/com/sandflow/smpte/util/HalfFloat.java index 83e251d..d57d51d 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/HalfFloat.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/HalfFloat.java @@ -30,6 +30,12 @@ */ public class HalfFloat { + /** + * Converts a half-float stored in an int into a double + * + * @param hf half-float stored in an int + * @return Half-float value as a double + */ public static double toDouble(int hf) { double val; diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/UL.java b/regxmllib/src/main/java/com/sandflow/smpte/util/UL.java index c54f78f..0629d60 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/UL.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/UL.java @@ -187,7 +187,12 @@ public boolean equalsWithMask(UL ul, int bytemask) { public boolean equals(UL ul) { return Arrays.equals(ul.value, this.value); } - + + /** + * Returns the sequence of bytes that make up the UL (in the order specified by ST 298 4122) + * + * @return Sequence of 16 bytes + */ public byte[] getValue() { return value; } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/UMID.java b/regxmllib/src/main/java/com/sandflow/smpte/util/UMID.java index fd5a274..f6370ae 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/UMID.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/UMID.java @@ -78,6 +78,11 @@ public UMID(byte[] umid) { this.value = java.util.Arrays.copyOf(umid, 32); } + /** + * Returns the sequence of bytes that make up the UMID (as specified in SMPTE ST 330) + * + * @return sequence of 32 bytes + */ public byte[] getValue() { return value; } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/UUID.java b/regxmllib/src/main/java/com/sandflow/smpte/util/UUID.java index 8f7f4be..101bf91 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/UUID.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/UUID.java @@ -52,6 +52,11 @@ public UUID(byte[] uuid) { this.value = java.util.Arrays.copyOf(uuid, 16); } + /** + * Returns the sequence of bytes that make up the UUID (in the order specified by RFC 4122) + * + * @return Sequence of 16 bytes + */ public byte[] getValue() { return this.value; } @@ -96,7 +101,8 @@ public static UUID fromRandom() { } /** - * Generate a Class 5 UUID using a URI name + * Generate a Class 5 UUID from a URI + * @param uri URI * @return Class 5 UUID */ public static UUID fromURIName(URI uri) { diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/AUIDAdapter.java b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/AUIDAdapter.java index 166f255..a6ddbd2 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/AUIDAdapter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/AUIDAdapter.java @@ -29,6 +29,9 @@ import com.sandflow.smpte.util.UL; import javax.xml.bind.annotation.adapters.XmlAdapter; +/** + * Unmarshals/marshals an xsd:string to/from a AIUD + */ public class AUIDAdapter extends XmlAdapter { @Override diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryByteAdapter.java b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryByteAdapter.java index 5215d60..bec9ba5 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryByteAdapter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryByteAdapter.java @@ -29,6 +29,9 @@ import static javax.xml.bind.DatatypeConverter.printHexBinary; import javax.xml.bind.annotation.adapters.XmlAdapter; +/** + * Unmarshals/marshals a byte from/to an xsd:string + */ public class HexBinaryByteAdapter extends XmlAdapter { @Override diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryLongAdapter.java b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryLongAdapter.java index 27efe2b..cdfcbb0 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryLongAdapter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/HexBinaryLongAdapter.java @@ -29,6 +29,9 @@ import javax.xml.bind.DatatypeConverter; import javax.xml.bind.annotation.adapters.XmlAdapter; +/** + * Unmarshals/marshals a hexadecimal integer from/to an xsd:string value + */ public class HexBinaryLongAdapter extends XmlAdapter { @Override diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/ULAdapter.java b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/ULAdapter.java index bd68570..d1c84ba 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/ULAdapter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/ULAdapter.java @@ -28,12 +28,17 @@ import com.sandflow.smpte.util.UL; import javax.xml.bind.annotation.adapters.XmlAdapter; +/** + * Unmarshals/marshals an xsd:string to/from a SMPTE UL + */ public class ULAdapter extends XmlAdapter { + @Override public UL unmarshal(String val) throws Exception { return UL.fromURN(val); } + @Override public String marshal(UL val) throws Exception { return val.toString(); } diff --git a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/UUIDAdapter.java b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/UUIDAdapter.java index bcd324a..c15d7e5 100644 --- a/regxmllib/src/main/java/com/sandflow/smpte/util/xml/UUIDAdapter.java +++ b/regxmllib/src/main/java/com/sandflow/smpte/util/xml/UUIDAdapter.java @@ -28,6 +28,9 @@ import com.sandflow.smpte.util.UUID; import javax.xml.bind.annotation.adapters.XmlAdapter; +/** + * Unmarshals/marshals an xsd:string to/from a UUID + */ public class UUIDAdapter extends XmlAdapter { @Override diff --git a/regxmllib/src/main/java/com/sandflow/util/events/BasicEvent.java b/regxmllib/src/main/java/com/sandflow/util/events/BasicEvent.java index ae1fd8c..04e6c86 100644 --- a/regxmllib/src/main/java/com/sandflow/util/events/BasicEvent.java +++ b/regxmllib/src/main/java/com/sandflow/util/events/BasicEvent.java @@ -36,6 +36,13 @@ public class BasicEvent implements Event { Severity severity; Enum code; + /** + * Creates an immutable BasicEvent instance + * + * @param severity Severity of the event + * @param code Uniquely identifies the event + * @param message Describes the event + */ public BasicEvent(Severity severity, Enum code, String message) { this.message = message; this.severity = severity; diff --git a/regxmllib/src/main/java/com/sandflow/util/events/Event.java b/regxmllib/src/main/java/com/sandflow/util/events/Event.java index fb69604..4f5652b 100644 --- a/regxmllib/src/main/java/com/sandflow/util/events/Event.java +++ b/regxmllib/src/main/java/com/sandflow/util/events/Event.java @@ -32,6 +32,9 @@ */ public interface Event { + /** + * Defines the four potential severity of an event + */ public static enum Severity { /**