Class MudlibWorldProjection

java.lang.Object
io.github.protasm.jvmud.engine.world.MudlibWorldProjection

public final class MudlibWorldProjection extends Object
Identity adapter between opaque mudlib objects and JVMud-native world locations.

The adapter contains no second containment graph. It only records projection identity; location and contents queries are always answered by the associated WorldRuntime.

  • Constructor Details

    • MudlibWorldProjection

      public MudlibWorldProjection(WorldRuntime worldRuntime)
      Creates an identity adapter backed by the supplied authoritative world runtime.
  • Method Details

    • worldRuntime

      public WorldRuntime worldRuntime()
      Returns the authoritative world runtime used by this adapter.
    • bindPlace

      public void bindPlace(Object object, Place place)
      Binds a mudlib object to an existing native place.
    • bindEntity

      public void bindEntity(Object object, Entity entity)
      Binds a mudlib object to an existing native entity.
    • move

      public void move(Object object, Object destination)
      Moves an opaque mudlib object using the native containment graph.
    • environment

      public Object environment(Object object)
      Returns the opaque object that immediately contains the supplied object.
    • inventory

      public List<Object> inventory(Object object)
      Returns the opaque objects immediately contained by the supplied object.
    • remove

      public void remove(Object object)
      Removes an opaque entity projection from the native world.