org.cpsolver.ifs.example.tt

## Class Resource.Context

- java.lang.Object
- - org.cpsolver.ifs.example.tt.Resource.Context

- All Implemented Interfaces:
    AssignmentConstraintContext<Activity,Location>, AssignmentContext
  Enclosing class:
    Resource

      public class Resource.Context
      extends Object
      implements AssignmentConstraintContext<Activity,Location>

  Assignment context

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Context(Assignment<Activity,Location> assignment)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `assigned(Assignment<Activity,Location> assignment, Location location)` Called when `ConstraintWithContext.assigned(Assignment, long, Value)` is called to update the content of the context.
    `Activity` | `getActivity(int slot)`
    `void` | `unassigned(Assignment<Activity,Location> assignment, Location location)` Called when `ConstraintWithContext.unassigned(Assignment, long, Value)` is called to update the content of the context.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### Context

          public Context(Assignment<Activity,Location> assignment)

  - ### Method Detail

    - #### assigned

          public void assigned(Assignment<Activity,Location> assignment,
                               Location location)

      Description copied from interface: `AssignmentConstraintContext`
      Called when `ConstraintWithContext.assigned(Assignment, long, Value)` is called to update the content of the context.
      Specified by:
        `assigned` in interface `AssignmentConstraintContext<Activity,Location>`
      Parameters:
        `assignment` - current assignment (with which this context is associated)
        `location` - assigned value

    - #### getActivity

          public Activity getActivity(int slot)

    - #### unassigned

          public void unassigned(Assignment<Activity,Location> assignment,
                                 Location location)

      Description copied from interface: `AssignmentConstraintContext`
      Called when `ConstraintWithContext.unassigned(Assignment, long, Value)` is called to update the content of the context.
      Specified by:
        `unassigned` in interface `AssignmentConstraintContext<Activity,Location>`
      Parameters:
        `assignment` - current assignment (with which this context is associated)
        `location` - unassigned value