Package codes.grow.packages.vault
Record Class RoleInfo
java.lang.Object
java.lang.Record
codes.grow.packages.vault.RoleInfo
- Record Components:
dbName- connection namecreationStatements- SQL run to create a userrevocationStatements- SQL run to drop a userrenewStatements- SQL run on renewalrollbackStatements- SQL run on failuredefaultTtl- default lease TTLmaxTtl- maximum lease TTLcredentialType- credential type, e.g.password
public record RoleInfo(String dbName, List<String> creationStatements, List<String> revocationStatements, List<String> renewStatements, List<String> rollbackStatements, Duration defaultTtl, Duration maxTtl, String credentialType)
extends Record
A database role.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecreationStatementsrecord component.Returns the value of thecredentialTyperecord component.dbName()Returns the value of thedbNamerecord component.Returns the value of thedefaultTtlrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.maxTtl()Returns the value of themaxTtlrecord component.Returns the value of therenewStatementsrecord component.Returns the value of therevocationStatementsrecord component.Returns the value of therollbackStatementsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RoleInfo
public RoleInfo(String dbName, List<String> creationStatements, List<String> revocationStatements, List<String> renewStatements, List<String> rollbackStatements, Duration defaultTtl, Duration maxTtl, String credentialType) Creates the record; lists are copied.- Parameters:
dbName- connection namecreationStatements- creation SQLrevocationStatements- revocation SQLrenewStatements- renew SQLrollbackStatements- rollback SQLdefaultTtl- default TTLmaxTtl- max TTLcredentialType- credential type
-
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
dbName
Returns the value of thedbNamerecord component.- Returns:
- the value of the
dbNamerecord component
-
creationStatements
Returns the value of thecreationStatementsrecord component.- Returns:
- the value of the
creationStatementsrecord component
-
revocationStatements
Returns the value of therevocationStatementsrecord component.- Returns:
- the value of the
revocationStatementsrecord component
-
renewStatements
Returns the value of therenewStatementsrecord component.- Returns:
- the value of the
renewStatementsrecord component
-
rollbackStatements
Returns the value of therollbackStatementsrecord component.- Returns:
- the value of the
rollbackStatementsrecord component
-
defaultTtl
Returns the value of thedefaultTtlrecord component.- Returns:
- the value of the
defaultTtlrecord component
-
maxTtl
Returns the value of themaxTtlrecord component.- Returns:
- the value of the
maxTtlrecord component
-
credentialType
Returns the value of thecredentialTyperecord component.- Returns:
- the value of the
credentialTyperecord component
-