Class EjbMessageBeanDescriptor

java.lang.Object
java.util.Observable
org.glassfish.deployment.common.DynamicAttributesDescriptor
org.glassfish.deployment.common.Descriptor
com.sun.enterprise.deployment.CommonResourceDescriptor
org.glassfish.ejb.deployment.descriptor.EjbDescriptor
org.glassfish.ejb.deployment.descriptor.EjbMessageBeanDescriptor
All Implemented Interfaces:
com.sun.enterprise.deployment.EjbDescriptor, com.sun.enterprise.deployment.EjbMessageBeanDescriptor, com.sun.enterprise.deployment.JndiNameEnvironment, com.sun.enterprise.deployment.NamedDescriptor, com.sun.enterprise.deployment.types.EjbReferenceContainer, com.sun.enterprise.deployment.types.MessageDestinationReferenceContainer, com.sun.enterprise.deployment.types.MessageDestinationReferencer, com.sun.enterprise.deployment.types.ResourceEnvReferenceContainer, com.sun.enterprise.deployment.types.ResourceReferenceContainer, com.sun.enterprise.deployment.types.ServiceReferenceContainer, com.sun.enterprise.deployment.WritableJndiNameEnvironment, Serializable

public final class EjbMessageBeanDescriptor extends EjbDescriptor implements com.sun.enterprise.deployment.types.MessageDestinationReferencer, com.sun.enterprise.deployment.EjbMessageBeanDescriptor
Objects of this kind represent the deployment information describing a single message driven Ejb.
See Also:
  • Constructor Details

    • EjbMessageBeanDescriptor

      public EjbMessageBeanDescriptor()
      Default constructor.
    • EjbMessageBeanDescriptor

      public EjbMessageBeanDescriptor(EjbMessageBeanDescriptor other)
      The copy constructor.
  • Method Details

    • getEjbTypeForDisplay

      public String getEjbTypeForDisplay()
      Specified by:
      getEjbTypeForDisplay in interface com.sun.enterprise.deployment.EjbDescriptor
      Specified by:
      getEjbTypeForDisplay in class EjbDescriptor
    • getType

      public String getType()
      Returns the type of this bean - always "Message-driven".
      Specified by:
      getType in interface com.sun.enterprise.deployment.EjbDescriptor
    • setContainerTransactionFor

      public void setContainerTransactionFor(com.sun.enterprise.deployment.MethodDescriptor methodDescriptor, ContainerTransaction containerTransaction)
      Description copied from class: EjbDescriptor
      Sets the container transaction for the given method descriptor. Throws an Illegal argument if this ejb has transaction type BEAN_TRANSACTION_TYPE.
      Overrides:
      setContainerTransactionFor in class EjbDescriptor
    • setType

      public void setType(String type)
      Sets my type
      Specified by:
      setType in class EjbDescriptor
    • setMessageListenerType

      public void setMessageListenerType(String messagingType)
    • getMessageListenerType

      public String getMessageListenerType()
      Specified by:
      getMessageListenerType in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • getTxBusinessMethodDescriptors

      public Set<com.sun.enterprise.deployment.MethodDescriptor> getTxBusinessMethodDescriptors()
      Overrides:
      getTxBusinessMethodDescriptors in class EjbDescriptor
      Returns:
      the full set of transactional business method descriptors I have.
    • getSecurityBusinessMethodDescriptors

      public Set getSecurityBusinessMethodDescriptors()
      Description copied from class: EjbDescriptor
      Returns the full set of security business method descriptors I have.
      Specified by:
      getSecurityBusinessMethodDescriptors in interface com.sun.enterprise.deployment.EjbDescriptor
      Overrides:
      getSecurityBusinessMethodDescriptors in class EjbDescriptor
    • getMessageListenerInterfaceMethods

      public Method[] getMessageListenerInterfaceMethods(ClassLoader classLoader) throws NoSuchMethodException
      This returns the message listener onMessage method from the *message listener interface* itself, as opposed to the method from the ejb class that implements it.
      Throws:
      NoSuchMethodException
    • getPossibleTransactionAttributes

      public Vector<ContainerTransaction> getPossibleTransactionAttributes()
      Overrides:
      getPossibleTransactionAttributes in class EjbDescriptor
      Returns:
      the set of transaction attributes that can be assigned to methods of this ejb when in CMT mode. Elements are of type ContainerTransaction
    • hasMessageDestinationLinkName

      public boolean hasMessageDestinationLinkName()
    • isLinkedToMessageDestination

      public boolean isLinkedToMessageDestination()
      Specified by:
      isLinkedToMessageDestination in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • getMessageDestinationLinkName

      public String getMessageDestinationLinkName()
      Specified by:
      getMessageDestinationLinkName in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
      Returns:
      the name of the message destination to which I refer
    • setMessageDestinationLinkName

      public void setMessageDestinationLinkName(String linkName)
      Sets the name of the message destination to which I refer.
      Specified by:
      setMessageDestinationLinkName in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • setMessageDestinationLinkName

      public com.sun.enterprise.deployment.MessageDestinationDescriptor setMessageDestinationLinkName(String linkName, boolean resolveLink)
      Specified by:
      setMessageDestinationLinkName in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • resolveLinkName

      public com.sun.enterprise.deployment.MessageDestinationDescriptor resolveLinkName()
      Specified by:
      resolveLinkName in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • ownedByMessageDestinationRef

      public boolean ownedByMessageDestinationRef()
      Specified by:
      ownedByMessageDestinationRef in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • getMessageDestinationRefOwner

      public com.sun.enterprise.deployment.MessageDestinationReferenceDescriptor getMessageDestinationRefOwner()
      Specified by:
      getMessageDestinationRefOwner in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • ownedByMessageBean

      public boolean ownedByMessageBean()
      True if the owner is a message-driven bean.
      Specified by:
      ownedByMessageBean in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • getMessageBeanOwner

      public EjbMessageBeanDescriptor getMessageBeanOwner()
      Get the descriptor for the message-driven bean owner.
      Specified by:
      getMessageBeanOwner in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
    • getMessageDestination

      public com.sun.enterprise.deployment.MessageDestinationDescriptor getMessageDestination()
      Specified by:
      getMessageDestination in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
      Returns:
      the message destination to which I refer. Can be NULL.
    • setMessageDestination

      public void setMessageDestination(com.sun.enterprise.deployment.MessageDestinationDescriptor newMsgDest)
      Specified by:
      setMessageDestination in interface com.sun.enterprise.deployment.types.MessageDestinationReferencer
      Parameters:
      newMsgDest - the message destination to which I refer.
    • getActivationConfigProperties

      public Set<com.sun.enterprise.deployment.EnvironmentProperty> getActivationConfigProperties()
      Specified by:
      getActivationConfigProperties in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
      Returns:
      Set of EnvironmentProperty elements.
    • getActivationConfigValue

      public String getActivationConfigValue(String name)
      Specified by:
      getActivationConfigValue in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • putActivationConfigProperty

      public void putActivationConfigProperty(com.sun.enterprise.deployment.EnvironmentProperty prop)
    • removeActivationConfigProperty

      public void removeActivationConfigProperty(com.sun.enterprise.deployment.EnvironmentProperty prop)
    • removeActivationConfigPropertyByName

      public void removeActivationConfigPropertyByName(String name)
    • getRuntimeActivationConfigProperties

      public Set<com.sun.enterprise.deployment.EnvironmentProperty> getRuntimeActivationConfigProperties()
      Specified by:
      getRuntimeActivationConfigProperties in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
      Returns:
      Set of EnvironmentProperty elements.
    • getRuntimeActivationConfigValue

      public String getRuntimeActivationConfigValue(String name)
    • putRuntimeActivationConfigProperty

      public void putRuntimeActivationConfigProperty(com.sun.enterprise.deployment.EnvironmentProperty prop)
      Specified by:
      putRuntimeActivationConfigProperty in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • removeRuntimeActivationConfigProperty

      public void removeRuntimeActivationConfigProperty(com.sun.enterprise.deployment.EnvironmentProperty prop)
    • removeRuntimeActivationConfigPropertyByName

      public void removeRuntimeActivationConfigPropertyByName(String name)
    • hasQueueDest

      public boolean hasQueueDest()
      Specified by:
      hasQueueDest in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • hasTopicDest

      public boolean hasTopicDest()
    • hasDestinationType

      public boolean hasDestinationType()
    • getDestinationType

      public String getDestinationType()
      Specified by:
      getDestinationType in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • setDestinationType

      public void setDestinationType(String destType)
    • hasDurableSubscription

      public boolean hasDurableSubscription()
    • setHasDurableSubscription

      public void setHasDurableSubscription(boolean durable)
    • setHasQueueDest

      public void setHasQueueDest()
    • setHasTopicDest

      public void setHasTopicDest()
    • setSubscriptionDurability

      public void setSubscriptionDurability(String subscription)
    • hasJmsMessageSelector

      public boolean hasJmsMessageSelector()
    • setJmsMessageSelector

      public void setJmsMessageSelector(String selector)
    • getJmsMessageSelector

      public String getJmsMessageSelector()
    • getJmsAcknowledgeMode

      public int getJmsAcknowledgeMode()
    • getJmsAcknowledgeModeAsString

      public String getJmsAcknowledgeModeAsString()
    • setJmsAcknowledgeMode

      public void setJmsAcknowledgeMode(int acknowledgeMode)
    • setJmsAcknowledgeMode

      public void setJmsAcknowledgeMode(String acknowledgeMode)
    • getDurableSubscriptionName

      public String getDurableSubscriptionName()
      Specified by:
      getDurableSubscriptionName in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • setDurableSubscriptionName

      public void setDurableSubscriptionName(String durableSubscriptionName)
    • getConnectionFactoryName

      public String getConnectionFactoryName()
    • setConnectionFactoryName

      public void setConnectionFactoryName(String connectionFactory)
      Connection factory is optional. If set to null, hasConnectionFactory will return false.
    • hasConnectionFactory

      public boolean hasConnectionFactory()
    • getResourceAdapterMid

      public String getResourceAdapterMid()
      Specified by:
      getResourceAdapterMid in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • getMdbConnectionFactoryJndiName

      public String getMdbConnectionFactoryJndiName()
      Specified by:
      getMdbConnectionFactoryJndiName in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • setResourceAdapterMid

      public void setResourceAdapterMid(String resourceAdapterMid)
      resource-adapter-mid is optional. It is set when a resource adapter is responsible for delivering messages to the message-driven bean. If not set, hasResourceAdapterMid will return false.
      Specified by:
      setResourceAdapterMid in interface com.sun.enterprise.deployment.EjbMessageBeanDescriptor
    • hasResourceAdapterMid

      public boolean hasResourceAdapterMid()
    • getMethods

      public Vector<Method> getMethods(ClassLoader classLoader)
      Overrides:
      getMethods in class EjbDescriptor
      Returns:
      the ejb method objects, i.e. the methods on the home and remote interfaces.
    • getTransactionMethods

      protected Collection<com.sun.enterprise.deployment.MethodDescriptor> getTransactionMethods(ClassLoader classLoader)
      Overrides:
      getTransactionMethods in class EjbDescriptor
      Returns:
      a collection of MethodDescriptor for methods which may have a assigned security attribute.
    • getContainerFactoryQualifier

      public String getContainerFactoryQualifier()
      Specified by:
      getContainerFactoryQualifier in class EjbDescriptor
    • setTransactionType

      public void setTransactionType(String transactionType)
      Sets the transaction type for this bean. Must be either BEAN_TRANSACTION_TYPE or CONTAINER_TRANSACTION_TYPE.
      Specified by:
      setTransactionType in class EjbDescriptor
    • setActivationConfigDescriptor

      public void setActivationConfigDescriptor(ActivationConfigDescriptor desc)
    • getActivationConfigDescriptor

      public ActivationConfigDescriptor getActivationConfigDescriptor()
    • setRuntimeActivationConfigDescriptor

      public void setRuntimeActivationConfigDescriptor(ActivationConfigDescriptor desc)
    • getRuntimeActivationConfigDescriptor

      public ActivationConfigDescriptor getRuntimeActivationConfigDescriptor()
    • print

      public void print(StringBuffer toStringBuffer)
      Appends a formatted String of the attributes of this object.
      Overrides:
      print in class EjbDescriptor