Class Scene

java.lang.Object
com._1c.g5.aef2.scenes.Scene
All Implemented Interfaces:
IServiceEventTracker, IScene

public final class Scene extends Object implements IScene
Default IScene implementation.
  • Constructor Details

    • Scene

      public Scene(IEngine engine)
      Instantiates a new scene.
      Parameters:
      engine - the engine to construct a scene for.
  • Method Details

    • getEngine

      public IEngine getEngine()
      Specified by:
      getEngine in interface IScene
      Returns:
      the engine this scene belongs to.
    • getRenderer

      public IRenderer<?> getRenderer()
      Specified by:
      getRenderer in interface IScene
      Returns:
      this scene renderer.
    • setComponent

      public void setComponent(IComponent<?> component)
      Description copied from interface: IScene
      Sets the root component of this scene.
      Specified by:
      setComponent in interface IScene
      Parameters:
      component - the component to set as the root.
    • getComponent

      public final IComponent<?> getComponent()
      Description copied from interface: IScene
      Returns the root component of this scene.
      Specified by:
      getComponent in interface IScene
      Returns:
      the root component of this scene.
    • setRenderer

      public void setRenderer(IRenderer<?> renderer)
      Description copied from interface: IScene
      Sets this scene renderer.
      Specified by:
      setRenderer in interface IScene
      Parameters:
      renderer - the renderer to set.
    • refresh

      public void refresh()
      Description copied from interface: IScene
      Refreshes this scene presentation completely.
      Specified by:
      refresh in interface IScene
    • relayout

      public void relayout()
      Description copied from interface: IScene
      Triggers this scene's layout processing.
      Specified by:
      relayout in interface IScene
    • refresh

      public void refresh(IComponent<?> component)
      Description copied from interface: IScene
      Refreshes this scene's subtree presentation starting at the given component.
      Specified by:
      refresh in interface IScene
      Parameters:
      component - the component to start from.
    • commit

      public void commit(IComponent<?> component)
      Description copied from interface: IScene
      Commits the model for the given component.
      Specified by:
      commit in interface IScene
      Parameters:
      component - the component to perform commit for.
      See Also:
    • addSceneListener

      public void addSceneListener(ISceneListener listener)
      Description copied from interface: IScene
      Adds this scene listener.
      Specified by:
      addSceneListener in interface IScene
      Parameters:
      listener - the listener to add.
    • removeSceneListener

      public void removeSceneListener(ISceneListener listener)
      Description copied from interface: IScene
      Removes this scene listener.
      Specified by:
      removeSceneListener in interface IScene
      Parameters:
      listener - the listener to remove.
    • dispose

      public void dispose()
      Description copied from interface: IScene
      Disposes this scene.
      Specified by:
      dispose in interface IScene
    • registerServiceConsumer

      public void registerServiceConsumer(IServiceConsumer<?> serviceConsumer)
      Description copied from interface: IScene
      Registers a given service consumer instance.
      Specified by:
      registerServiceConsumer in interface IScene
      Parameters:
      serviceConsumer - a service consumer.
      See Also:
    • trackEvent

      public void trackEvent(IServiceEvent event)
      Description copied from interface: IServiceEventTracker
      Tracks the given event.
      Specified by:
      trackEvent in interface IServiceEventTracker
      Parameters:
      event - the service event.
    • registerSearchProvider

      public void registerSearchProvider(IComponentSearchProvider searchProvider)
      Description copied from interface: IScene
      Registers a provider to be used by the scene for searching components.
      Specified by:
      registerSearchProvider in interface IScene
      Parameters:
      searchProvider - The search provider
    • unregisterSearchProvider

      public void unregisterSearchProvider(IComponentSearchProvider searchProvider)
      Description copied from interface: IScene
      Unregisters a provider used by the scene for searching components.
      Specified by:
      unregisterSearchProvider in interface IScene
    • queueEvent

      public void queueEvent(Object query, IClientEvent event)
      Description copied from interface: IScene
      Finds a component by a query using the registered search providers and queues an event for it.
      Specified by:
      queueEvent in interface IScene
      Parameters:
      query - The query for identifying the component to queue the event to
      event - The event to be queued
      See Also:
    • handleComponentEvent

      public void handleComponentEvent(IComponent<?> component, IEvent event)
      Description copied from interface: IScene
      Notifies the scene that a component-specific event has happened.
      Specified by:
      handleComponentEvent in interface IScene
      Parameters:
      component - The component from which originates the event
      event - The event that has happened with the component
    • putState

      public IState putState(IComponent<?> component, IState state)
      Description copied from interface: IScene
      Puts the specified state for the given component.
      Specified by:
      putState in interface IScene
      Parameters:
      component - the component, cannot be null.
      state - the state, can be null if there are no previous state for the specified component
      Returns:
      the previous stored state, can be null.
    • clearState

      public IState clearState(IComponent<?> component)
      Description copied from interface: IScene
      Clears state for the given component.
      Specified by:
      clearState in interface IScene
      Parameters:
      component - the component, cannot be null.
      Returns:
      the previous stored state, can be null if there are no state for the specified component.
    • getState

      public IState getState(IComponent<?> component)
      Description copied from interface: IScene
      Returns the current state for the given component.
      Specified by:
      getState in interface IScene
      Parameters:
      component - the component, cannot be null.
      Returns:
      the current state, can be null if there are no state for the specified component.