Class OptionalMethodSupport

java.lang.Object
org.soliscode.test.OptionalMethodSupport
All Implemented Interfaces:
SupportedMethods
Direct Known Subclasses:
AbstractBreakable, AbstractTest

public abstract class OptionalMethodSupport extends Object implements SupportedMethods
A utility class that provides an implementation for the SupportedMethods interface.
Since:
1.0
Author:
evanbergstrom
  • Constructor Details

    • OptionalMethodSupport

      protected OptionalMethodSupport()
    • OptionalMethodSupport

      protected OptionalMethodSupport(@NotNull @NotNull OptionalMethodSupport other)
  • Method Details

    • supportsMethod

      public boolean supportsMethod(@NotNull @NotNull OptionalMethod method)
      Description copied from interface: SupportedMethods
      Used to determine if this object supports an optional method.
      Specified by:
      supportsMethod in interface SupportedMethods
      Parameters:
      method - The identifier for the method.
      Returns:
      'true' if the method is supported. false if it is not.
    • doesNotSupportMethod

      public void doesNotSupportMethod(@NotNull @NotNull OptionalMethod method)
      Specifies that the class does not support the method passed as an argument.
      Parameters:
      method - the method that is not supported.
    • unsupportedMethods

      @NotNull protected @NotNull Collection<OptionalMethod> unsupportedMethods()
      Returns a collection if the methods that are not supported by the class being tested.
      Returns:
      a collection of unsupported methods.