public class InternalEntityFactory extends InternalFactory
InternalFactory.FactoryConstructionTracker
Constructor and Description |
---|
InternalEntityFactory(ManagementContextInternal managementContext,
EntityTypeRegistry entityTypeRegistry,
InternalPolicyFactory policyFactory) |
Modifier and Type | Method and Description |
---|---|
<T extends Entity> |
constructEntity(java.lang.Class<T> clazz,
java.lang.Iterable<java.lang.Class<?>> interfaces,
java.lang.String entityId)
Constructs a new-style entity (fails if no no-arg constructor).
|
<T extends Entity> |
createEntity(EntitySpec<T> spec,
<any> entityId)
creates a new entity instance from a spec, with all children, policies, etc,
fully initialized (
AbstractEntity.init() invoked) and ready for
management -- commonly the caller will next call
Entities.manage(Entity) (if it's in a managed application)
or Entities#startManagement(org.apache.brooklyn.api.entity.Application, org.apache.brooklyn.api.management.ManagementContext)
(if it's an application) |
<T extends Entity> |
createEntityProxy(EntitySpec<T> spec,
T entity) |
isNewStyle
public InternalEntityFactory(ManagementContextInternal managementContext, EntityTypeRegistry entityTypeRegistry, InternalPolicyFactory policyFactory)
public <T extends Entity> T createEntityProxy(EntitySpec<T> spec, T entity)
public <T extends Entity> T createEntity(EntitySpec<T> spec, <any> entityId)
AbstractEntity.init()
invoked) and ready for
management -- commonly the caller will next call
Entities.manage(Entity)
(if it's in a managed application)
or Entities#startManagement(org.apache.brooklyn.api.entity.Application, org.apache.brooklyn.api.management.ManagementContext)
(if it's an application)public <T extends Entity> T constructEntity(java.lang.Class<T> clazz, java.lang.Iterable<java.lang.Class<?>> interfaces, java.lang.String entityId)
For use during rebind.