org.kie.internal.runtime.conf

## Class ObjectModel

- java.lang.Object
- - org.kie.internal.runtime.conf.ObjectModel

- All Implemented Interfaces:
    Serializable
  Direct Known Subclasses:
    NamedObjectModel

      public class ObjectModel
      extends Object
      implements Serializable

  Object model that defines how and of what type the object instance should be created.
  The how is actually delegated to resolved implementation `ObjectModelResolver` that default to Java Reflection based resolver but might utilize others (such as MVEL, Spring, CDI, etc).
  The what type is derived from identifier (which should be FQCN in case of reflection) that is then used to create instance of that object using constructor. Which constructor is taken depends on defined parameters which might be again an ObjectModel for complex types. String types are supported directly, all other should be represented as ObjectModel.
  There are some key words acceptable that directly will refer to available instances:
  - runtimeManager - to get RuntimeManager instance injected
  - runtimeEngine - to get RuntimeEngine instance injected
  - ksession - to get KieSession instance injected
  - taskService - to get TaskService instance injected
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ObjectModel()`
    `ObjectModel(String identifier, Object... parameters)`
    `ObjectModel(String resolver, String identifier, Object... parameters)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addParameter(Object parameter)`
    `boolean` | `equals(Object obj)`
    `String` | `getIdentifier()`
    `List<Object>` | `getParameters()`
    `String` | `getResolver()`
    `int` | `hashCode()`
    `void` | `setIdentifier(String classname)`
    `void` | `setParameters(List<Object> parameters)`
    `void` | `setResolver(String resolver)`

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

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

- - ### Constructor Detail

    - #### ObjectModel

          public ObjectModel()

    - #### ObjectModel

          public ObjectModel(String identifier,
                             Object... parameters)

    - #### ObjectModel

          public ObjectModel(String resolver,
                             String identifier,
                             Object... parameters)

  - ### Method Detail

    - #### getIdentifier

          public String getIdentifier()

    - #### setIdentifier

          public void setIdentifier(String classname)

    - #### getParameters

          public List<Object> getParameters()

    - #### setParameters

          public void setParameters(List<Object> parameters)

    - #### addParameter

          public void addParameter(Object parameter)

    - #### getResolver

          public String getResolver()

    - #### setResolver

          public void setResolver(String resolver)

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### equals

          public boolean equals(Object obj)

      Overrides:
        `equals` in class `Object`

Copyright © 2001–2017 JBoss by Red Hat. All rights reserved.