Class AbstractBooleanStatementSupport<D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>>

Type Parameters:
D - Declared Statement representation
E - Effective Statement representation
All Implemented Interfaces:
StatementFactory<Boolean,D,E>

@Beta public abstract class AbstractBooleanStatementSupport<D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>> extends AbstractStatementSupport<Boolean,D,E>
Specialization of AbstractStatementSupport for statements which carry a Boolean argument and are essentially context-independent.
  • Constructor Details

    • AbstractBooleanStatementSupport

      protected AbstractBooleanStatementSupport(org.opendaylight.yangtools.yang.model.api.meta.StatementDefinition publicDefinition, E emptyEffectiveFalse, E emptyEffectiveTrue, StatementSupport.StatementPolicy<Boolean,D> policy, org.opendaylight.yangtools.yang.parser.api.YangParserConfiguration config, @Nullable SubstatementValidator validator)
  • Method Details

    • parseArgumentValue

      public final Boolean parseArgumentValue(StmtContext<?,?,?> ctx, String value)
      Description copied from class: StatementSupport
      Parses textual representation of argument in object representation.
      Specified by:
      parseArgumentValue in class StatementSupport<Boolean,D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>>
      Parameters:
      ctx - Context, which may be used to access source-specific namespaces required for parsing.
      value - String representation of value, as was present in text source.
      Returns:
      Parsed value
    • internArgument

      public final String internArgument(String rawArgument)
      Description copied from class: StatementSupport
      Given a raw string representation of an argument, try to use a shared representation. Default implementation does nothing.
      Overrides:
      internArgument in class StatementSupport<Boolean,D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>>
      Parameters:
      rawArgument - Argument string
      Returns:
      A potentially-shard instance
    • createDeclared

      protected final D createDeclared(BoundStmtCtx<Boolean> ctx, com.google.common.collect.ImmutableList<org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<?>> substatements)
      Specified by:
      createDeclared in class AbstractStatementSupport<Boolean,D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>>
    • createDeclared

      protected abstract @NonNull D createDeclared(@NonNull Boolean argument, @NonNull com.google.common.collect.ImmutableList<org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<?>> substatements)
    • createEffective

      protected final E createEffective(EffectiveStmtCtx.Current<Boolean,D> stmt, com.google.common.collect.ImmutableList<? extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<?,?>> substatements)
      Specified by:
      createEffective in class AbstractStatementSupport<Boolean,D extends org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement<Boolean>,E extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<Boolean,D>>
    • createEffective

      protected abstract @NonNull E createEffective(@NonNull D declared, com.google.common.collect.ImmutableList<? extends org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement<?,?>> substatements)
    • createEmptyEffective

      protected abstract @NonNull E createEmptyEffective(@NonNull D declared)