Package net.sf.saxon.ma.json
Record Class JsonReceiver.EscapeOptions
java.lang.Object
java.lang.Record
net.sf.saxon.ma.json.JsonReceiver.EscapeOptions
- Record Components:
retainQuot- true if the quotation marks should not be escapedretainSlash- true if solidus (forwards slash) should not be escapedupperCaseHex- true if hexadecimal digits are to be uppercasehexEscapes- a predicate identifying characters that should be output as hex escapes using \ u XXXX notation.
- Enclosing class:
JsonReceiver
public static record JsonReceiver.EscapeOptions(boolean retainQuot, boolean retainSlash, boolean upperCaseHex, IntPredicateProxy hexEscapes)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionEscapeOptions(boolean retainQuot, boolean retainSlash, boolean upperCaseHex, IntPredicateProxy hexEscapes) Creates an instance of aEscapeOptionsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thehexEscapesrecord component.booleanReturns the value of theretainQuotrecord component.booleanReturns the value of theretainSlashrecord component.final StringtoString()Returns a string representation of this record class.booleanReturns the value of theupperCaseHexrecord component.
-
Constructor Details
-
EscapeOptions
public EscapeOptions(boolean retainQuot, boolean retainSlash, boolean upperCaseHex, IntPredicateProxy hexEscapes) Creates an instance of aEscapeOptionsrecord class.- Parameters:
retainQuot- the value for theretainQuotrecord componentretainSlash- the value for theretainSlashrecord componentupperCaseHex- the value for theupperCaseHexrecord componenthexEscapes- the value for thehexEscapesrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
retainQuot
public boolean retainQuot()Returns the value of theretainQuotrecord component.- Returns:
- the value of the
retainQuotrecord component
-
retainSlash
public boolean retainSlash()Returns the value of theretainSlashrecord component.- Returns:
- the value of the
retainSlashrecord component
-
upperCaseHex
public boolean upperCaseHex()Returns the value of theupperCaseHexrecord component.- Returns:
- the value of the
upperCaseHexrecord component
-
hexEscapes
Returns the value of thehexEscapesrecord component.- Returns:
- the value of the
hexEscapesrecord component
-