com.fusesource.fmc.restjmx.resources
Class AttributeResource

java.lang.Object
  extended by com.fusesource.fmc.restjmx.resources.AttributeResource

public class AttributeResource
extends java.lang.Object

The resource for a MBean

Version:
$Revision: 1.0 $

Constructor Summary
AttributeResource(java.lang.String uriPath, java.lang.String namespace, javax.management.ObjectName objectName, javax.management.MBeanAttributeInfo attributeInfo, java.lang.Object value)
           
 
Method Summary
 Attribute getAttribute()
          Returns this MBean
 java.lang.String getDescription()
           
 boolean getIsWritable()
           
 java.lang.String getName()
           
 java.lang.String getNamespace()
           
 java.lang.String getObjectName()
           
 java.lang.String getType()
           
 java.lang.String getUriPath()
           
 java.lang.String getValue()
           
 javax.ws.rs.core.Response postMessage(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.HttpHeaders headers, java.lang.String val)
          Posts an update to the attribute value with the payload being text, XML or JSON
 javax.ws.rs.core.Response postMessageForm(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.HttpHeaders headers, com.sun.jersey.api.representation.Form formData)
          Posts an update to the attribute value taking the form data and extracting the body field as the new value.
protected  javax.ws.rs.core.Response setAttributeAndRedirect(javax.ws.rs.core.UriInfo uriInfo, javax.ws.rs.core.HttpHeaders headers, java.lang.String val)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttributeResource

public AttributeResource(java.lang.String uriPath,
                         java.lang.String namespace,
                         javax.management.ObjectName objectName,
                         javax.management.MBeanAttributeInfo attributeInfo,
                         java.lang.Object value)
Method Detail

getAttribute

public Attribute getAttribute()
                       throws java.lang.Exception
Returns this MBean

Throws:
java.lang.Exception

postMessage

public javax.ws.rs.core.Response postMessage(@Context
                                             javax.ws.rs.core.UriInfo uriInfo,
                                             @Context
                                             javax.ws.rs.core.HttpHeaders headers,
                                             java.lang.String val)
                                      throws java.lang.Exception
Posts an update to the attribute value with the payload being text, XML or JSON

Throws:
java.lang.Exception

postMessageForm

public javax.ws.rs.core.Response postMessageForm(@Context
                                                 javax.ws.rs.core.UriInfo uriInfo,
                                                 @Context
                                                 javax.ws.rs.core.HttpHeaders headers,
                                                 com.sun.jersey.api.representation.Form formData)
                                          throws java.lang.Exception
Posts an update to the attribute value taking the form data and extracting the body field as the new value.

Throws:
java.lang.Exception

setAttributeAndRedirect

protected javax.ws.rs.core.Response setAttributeAndRedirect(javax.ws.rs.core.UriInfo uriInfo,
                                                            javax.ws.rs.core.HttpHeaders headers,
                                                            java.lang.String val)
                                                     throws java.lang.Exception
Throws:
java.lang.Exception

getUriPath

public java.lang.String getUriPath()

getNamespace

public java.lang.String getNamespace()

getObjectName

public java.lang.String getObjectName()

getName

public java.lang.String getName()

getType

public java.lang.String getType()

getDescription

public java.lang.String getDescription()

getIsWritable

public boolean getIsWritable()

getValue

public java.lang.String getValue()


Copyright © 2012 FuseSource. All Rights Reserved.