Class UserTypeSpecification<T extends UserTypeSpecification<T>>

java.lang.Object
org.springframework.data.cassandra.core.cql.keyspace.UserTypeNameSpecification
org.springframework.data.cassandra.core.cql.keyspace.UserTypeSpecification<T>
Direct Known Subclasses:
CreateUserTypeSpecification

public class UserTypeSpecification<T extends UserTypeSpecification<T>> extends UserTypeNameSpecification
Object to support the configuration of user type specifications that have columns. This class can also be used as a standalone UserTypeSpecification.
Since:
1.5
Author:
Fabio J. Mendes, Mark Paluch
See Also:
  • CqlIdentifier
  • Constructor Details

    • UserTypeSpecification

      protected UserTypeSpecification(com.datastax.oss.driver.api.core.CqlIdentifier name)
  • Method Details

    • field

      public T field(String name, com.datastax.oss.driver.api.core.type.DataType type)
      Adds the given field to the type.
      Parameters:
      name - must not be null or empty.
      type - The data type of the field.
      Returns:
      this specification.
    • field

      public T field(com.datastax.oss.driver.api.core.CqlIdentifier name, com.datastax.oss.driver.api.core.type.DataType type)
      Adds an ADD to the list of field changes.
      Parameters:
      name - must not null.
      type - must not be null.
      Returns:
      this specification.
    • getFields

      public List<FieldSpecification> getFields()
      Returns:
      an unmodifiable list of all fields.