java.lang.Object
java.lang.Record
io.helidon.codegen.CodegenScope
- Record Components:
name
- name of the scope, use empty string for production scope, seePRODUCTION
, use lower case names
Scope of the current code generation session.
-
Field Summary
-
Constructor Summary
ConstructorDescriptionCodegenScope
(String name) Creates an instance of aCodegenScope
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.boolean
Whether this is a production scope.name()
Returns the value of thename
record component.prefix()
Type prefix for this scope.final String
toString()
Returns a string representation of this record class.
-
Field Details
-
PRODUCTION
Production scope.
-
-
Constructor Details
-
CodegenScope
Creates an instance of aCodegenScope
record class.- Parameters:
name
- the value for thename
record component
-
-
Method Details
-
isProduction
public boolean isProduction()Whether this is a production scope.- Returns:
- if production
-
prefix
Type prefix for this scope.- Returns:
- the scope name with first letter as capital
-
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. All components in this record class are compared withObjects::equals(Object,Object)
. -
name
Returns the value of thename
record component.- Returns:
- the value of the
name
record component
-