Module org.postgresql.pljava
Package org.postgresql.pljava.sqlgen
Class Lexicals.Identifier.Operator
java.lang.Object
org.postgresql.pljava.sqlgen.Lexicals.Identifier
org.postgresql.pljava.sqlgen.Lexicals.Identifier.Unqualified<Lexicals.Identifier.Operator>
org.postgresql.pljava.sqlgen.Lexicals.Identifier.Operator
- All Implemented Interfaces:
Serializable
- Enclosing class:
Lexicals.Identifier
public static class Lexicals.Identifier.Operator
extends Lexicals.Identifier.Unqualified<Lexicals.Identifier.Operator>
Class representing an Identifier that names a PostgreSQL operator.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.postgresql.pljava.sqlgen.Lexicals.Identifier
Lexicals.Identifier.None, Lexicals.Identifier.Operator, Lexicals.Identifier.Pseudo, Lexicals.Identifier.Qualified<T extends Lexicals.Identifier.Unqualified<T>>, Lexicals.Identifier.Simple, Lexicals.Identifier.Unqualified<T extends Lexicals.Identifier.Unqualified<T>>
-
Method Summary
Modifier and TypeMethodDescriptionThis Identifier represented as it would be in SQL source.deparse
(Lexicals.Identifier.Simple qualifier, Charset cs) Produce the deparsed form of a qualified identifier with the given qualifier and this as the local part.boolean
For use in an annotation processor, a version ofequals
that can take aMessager
and use it to emit warnings.static Lexicals.Identifier.Operator
Create anIdentifier.Operator
from a name string.static Lexicals.Identifier.Operator
Create anIdentifier.Operator
from a name string.int
hashCode()
Returns a hash code value for the object.withQualifier
(Lexicals.Identifier.Simple qualifier) Form anIdentifier.Qualified
with this as the local part.Methods inherited from class org.postgresql.pljava.sqlgen.Lexicals.Identifier
equals, isUnnamed, toString
-
Method Details
-
from
Create anIdentifier.Operator
from a name string.Equivalent to
from(s, null)
. -
from
Create anIdentifier.Operator
from a name string.There are not different ways to represent an operator in Java source and in the PostgreSQL catalogs, so there do not need to be
fromCatalog
andfromJava
flavors of this method.- Parameters:
name
- The operator name.msgr
- a Messager for reporting diagnostics at compile time, or null if not in a compilation context.
-
withQualifier
public Lexicals.Identifier.Qualified<Lexicals.Identifier.Operator> withQualifier(Lexicals.Identifier.Simple qualifier) Description copied from class:Lexicals.Identifier.Unqualified
Form anIdentifier.Qualified
with this as the local part.- Specified by:
withQualifier
in classLexicals.Identifier.Unqualified<Lexicals.Identifier.Operator>
-
hashCode
public int hashCode()Returns a hash code value for the object. -
equals
Description copied from class:Lexicals.Identifier
For use in an annotation processor, a version ofequals
that can take aMessager
and use it to emit warnings. It will emit a warning whenever it compares two Identifiers that are equal by one or the other of PostgreSQL's or ISO SQL's rules but not both.- Specified by:
equals
in classLexicals.Identifier
- Parameters:
other
- Object to compare tomsgr
- a Messager to use for warnings; ifnull
, no warnings will be generated.- Returns:
- true if two quoted Identifiers match exactly, or two non-quoted ones match in either the PostgreSQL or ISO SQL folded form, or a quoted one exactly matches either folded form of a non-quoted one.
-
deparse
Description copied from class:Lexicals.Identifier
This Identifier represented as it would be in SQL source.The passed
Charset
indicates the character encoding in which the deparsed result will be stored; the method should verify that the characters can be encoded there, or use the Unicode delimited identifier form and escape the ones that cannot.- Specified by:
deparse
in classLexicals.Identifier
- Returns:
- The identifier, quoted, unless it is folding.
-
deparse
Description copied from class:Lexicals.Identifier.Unqualified
Produce the deparsed form of a qualified identifier with the given qualifier and this as the local part.- Specified by:
deparse
in classLexicals.Identifier.Unqualified<Lexicals.Identifier.Operator>
-