Package org.nuxeo.runtime.avro
Class AvroReplacementDescriptor
- java.lang.Object
-
- org.nuxeo.runtime.avro.AvroReplacementDescriptor
-
- All Implemented Interfaces:
Comparable<AvroReplacementDescriptor>
,Descriptor
public class AvroReplacementDescriptor extends Object implements Descriptor, Comparable<AvroReplacementDescriptor>
The Avro forbidden character replacement descriptor.
Avro allows alphanumeric characters and underscores in names.
Nuxeo Studio allows alphanumeric characters, underscores and dashes that have to be replaced by another symbol.
The default contributions provide replacement for :
- "-" as "__dash__"
- ":" as "__colon__
- ";" as "__semicolon__"
- and with higher priority "__" as "____" to ensure no user string is wrongly replaced.- Since:
- 10.2
-
-
Field Summary
Fields Modifier and Type Field Description protected String
forbidden
protected int
priority
protected String
replacement
-
Fields inherited from interface org.nuxeo.runtime.model.Descriptor
UNIQUE_DESCRIPTOR_ID
-
-
Constructor Summary
Constructors Constructor Description AvroReplacementDescriptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(AvroReplacementDescriptor o)
boolean
equals(Object obj)
String
getId()
The descriptor id, descriptors with same id are merged.int
hashCode()
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nuxeo.runtime.model.Descriptor
doesRemove, merge
-
-
-
-
Method Detail
-
compareTo
public int compareTo(AvroReplacementDescriptor o)
- Specified by:
compareTo
in interfaceComparable<AvroReplacementDescriptor>
-
getId
public String getId()
Description copied from interface:Descriptor
The descriptor id, descriptors with same id are merged.To forbid multiple descriptors use UNIQUE_DESCRIPTOR_ID.
To forbid merge use a unique value, non-overriden
toString()
for exemple.- Specified by:
getId
in interfaceDescriptor
-
-