Class OptionsSchema.Builder

java.lang.Object
org.refcodes.schema.Schema.Builder
org.refcodes.runtime.OptionsSchema.Builder
All Implemented Interfaces:
org.refcodes.exception.ExceptionAccessor.ExceptionBuilder<Throwable,org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.AliasAccessor.AliasBuilder<org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.ChildrenAccessor.ChildrenBuilder<org.refcodes.schema.Schema[],org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.DescriptionAccessor.DescriptionBuilder<org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.HashAccessor.HashBuilder<org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.IdentifierAccessor.IdentifierBuilder<org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.InstanceAccessor.InstanceBuilder<Object,org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.KeyAccessor.KeyBuilder<String,org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.StereotypeAccessor.StereotypeBuilder<String,org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.TypeAccessor.TypeBuilder<Class<?>,org.refcodes.schema.Schema.Builder>, org.refcodes.mixin.ValueAccessor.ValueBuilder<Object,org.refcodes.schema.Schema.Builder>
Enclosing class:
OptionsSchema

public static final class OptionsSchema.Builder extends org.refcodes.schema.Schema.Builder
Builder for creating OptionsSchema instances.

The builder collects common schema metadata (identifier, alias, key, type, hash, description, stereotype, exception, value), custom options, and optional children.

  • Method Details

    • withIdentifier

      public OptionsSchema.Builder withIdentifier(String aIdentifier)
      Specified by:
      withIdentifier in interface org.refcodes.mixin.IdentifierAccessor.IdentifierBuilder<org.refcodes.schema.Schema.Builder>
      Overrides:
      withIdentifier in class org.refcodes.schema.Schema.Builder
    • withAlias

      public OptionsSchema.Builder withAlias(String aAlias)
      Specified by:
      withAlias in interface org.refcodes.mixin.AliasAccessor.AliasBuilder<org.refcodes.schema.Schema.Builder>
      Overrides:
      withAlias in class org.refcodes.schema.Schema.Builder
    • withKey

      public OptionsSchema.Builder withKey(String aKey)
      Specified by:
      withKey in interface org.refcodes.mixin.KeyAccessor.KeyBuilder<String,org.refcodes.schema.Schema.Builder>
      Overrides:
      withKey in class org.refcodes.schema.Schema.Builder
    • withType

      public OptionsSchema.Builder withType(Class aType)
      Specified by:
      withType in interface org.refcodes.mixin.TypeAccessor.TypeBuilder<Class<?>,org.refcodes.schema.Schema.Builder>
      Overrides:
      withType in class org.refcodes.schema.Schema.Builder
    • withHash

      public OptionsSchema.Builder withHash(int aHash)
      Specified by:
      withHash in interface org.refcodes.mixin.HashAccessor.HashBuilder<org.refcodes.schema.Schema.Builder>
      Overrides:
      withHash in class org.refcodes.schema.Schema.Builder
    • withInstance

      public OptionsSchema.Builder withInstance(Object aInstance)
      Specified by:
      withInstance in interface org.refcodes.mixin.InstanceAccessor.InstanceBuilder<Object,org.refcodes.schema.Schema.Builder>
      Overrides:
      withInstance in class org.refcodes.schema.Schema.Builder
    • withStereotype

      public OptionsSchema.Builder withStereotype(String aStereotype)
      Specified by:
      withStereotype in interface org.refcodes.mixin.StereotypeAccessor.StereotypeBuilder<String,org.refcodes.schema.Schema.Builder>
      Overrides:
      withStereotype in class org.refcodes.schema.Schema.Builder
    • withValue

      public OptionsSchema.Builder withValue(Object aValue)
      Specified by:
      withValue in interface org.refcodes.mixin.ValueAccessor.ValueBuilder<Object,org.refcodes.schema.Schema.Builder>
      Overrides:
      withValue in class org.refcodes.schema.Schema.Builder
    • withException

      public OptionsSchema.Builder withException(Throwable aException)
      Specified by:
      withException in interface org.refcodes.exception.ExceptionAccessor.ExceptionBuilder<Throwable,org.refcodes.schema.Schema.Builder>
      Overrides:
      withException in class org.refcodes.schema.Schema.Builder
    • withDescription

      public OptionsSchema.Builder withDescription(String aDescription)
      Specified by:
      withDescription in interface org.refcodes.mixin.DescriptionAccessor.DescriptionBuilder<org.refcodes.schema.Schema.Builder>
      Overrides:
      withDescription in class org.refcodes.schema.Schema.Builder
    • withSchema

      public OptionsSchema.Builder withSchema(org.refcodes.schema.Schema aSchema)
      Overrides:
      withSchema in class org.refcodes.schema.Schema.Builder
    • withChildren

      public OptionsSchema.Builder withChildren(org.refcodes.schema.Schema... aChildren)
      Specified by:
      withChildren in interface org.refcodes.mixin.ChildrenAccessor.ChildrenBuilder<org.refcodes.schema.Schema[],org.refcodes.schema.Schema.Builder>
      Overrides:
      withChildren in class org.refcodes.schema.Schema.Builder
    • withChildren

      public OptionsSchema.Builder withChildren(Collection<? extends org.refcodes.schema.Schema> aChildren)
      Overrides:
      withChildren in class org.refcodes.schema.Schema.Builder
    • withProperty

      public OptionsSchema.Builder withProperty(String aKey, Object aValue)
      Overrides:
      withProperty in class org.refcodes.schema.Schema.Builder
    • build

      public OptionsSchema build()
      Overrides:
      build in class org.refcodes.schema.Schema.Builder