geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwo...@apache.org
Subject svn commit: r883992 [1/2] - in /geronimo/sandbox/rex: org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/ org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/ org.ap...
Date Wed, 25 Nov 2009 06:46:16 GMT
Author: rwonly
Date: Wed Nov 25 06:46:13 2009
New Revision: 883992

URL: http://svn.apache.org/viewvc?rev=883992&view=rev
Log:
some codes clean up.

Modified:
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/Util.java
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx/src/main/java/org/apache/geronimo/blueprint/jmx/BlueprintStateMBean.java

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java Wed Nov 25 06:46:13 2009
@@ -16,115 +16,109 @@
 import org.osgi.service.blueprint.reflect.ServiceMetadata;
 import org.osgi.service.blueprint.reflect.ServiceReferenceMetadata;
 
-public class BlueprintMetadata implements BlueprintMetadataMBean{
+public class BlueprintMetadata implements BlueprintMetadataMBean {
 
-	BundleContext bundleContext;
-	
-	public BlueprintMetadata(BundleContext bundleContext)
-	{
-		this.bundleContext = bundleContext;
-	}
-	
-	/*
-	 * (non-Javadoc)
-	 * @see org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean#getBlueprintContainerServiceId(long)
-	 */
-	public long getBlueprintContainerServiceId(long bundleId)
-			throws IOException {
-		Bundle bpBundle = bundleContext.getBundle(bundleId);
-		
-		String filter = "(&(osgi.blueprint.container.symbolicname=" //no similar one in interfaces
-			+bpBundle.getSymbolicName()
-			+")(osgi.blueprint.container.version=" 
-			+bpBundle.getVersion()
-			+"))";
-		ServiceReference [] serviceReferences = null;
-		try {
-			serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
-		} catch (InvalidSyntaxException e) {
-			throw new RuntimeException(e);
-		}
-		if(serviceReferences != null)
-			return (Long)serviceReferences[0].getProperty(Constants.SERVICE_ID);
-		else 
-			return -1;
-	}
-
-	public long[] getBlueprintContainerServiceIds() throws IOException {
-		ServiceReference [] serviceReferences = null;;
-		try {
-			serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), null);
-		} catch (InvalidSyntaxException e) {
-		}
-		long [] serviceIds = new long[serviceReferences.length];
-		for(int i = 0;i<serviceReferences.length;i++)
-		{
-			serviceIds[i] = (Long)serviceReferences[i].getProperty(Constants.SERVICE_ID);
-		}
-		return serviceIds;
-	}
-
-	public String[] getComponentIds(long containerServiceId) {
-		String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
-		ServiceReference [] serviceReferences = null;
-		try {
-			serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
-		} catch (InvalidSyntaxException e) {
-			throw new RuntimeException(e);
-		}
-		if(serviceReferences == null)
-			return null;
-		BlueprintContainer container = (BlueprintContainer)bundleContext.getService(serviceReferences[0]);
-		return (String [])container.getComponentIds().toArray();
-	}
-	/*
-	 * 
-	 * type could be Bean, Service, serviceReference
-	 * (non-Javadoc)
-	 * @see org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean#getComponentIdsByType(long, java.lang.String)
-	 */
-	public String[] getComponentIdsByType(long containerServiceId, String type) {
-		String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
-		ServiceReference [] serviceReferences = null;
-		try {
-			serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
-		} catch (InvalidSyntaxException e) {
-			throw new RuntimeException(e);
-		}
-		if(serviceReferences == null)
-			return null;
-		BlueprintContainer container = (BlueprintContainer)bundleContext.getService(serviceReferences[0]);
-		ComponentMetadata [] components;
-		if(type.equals(BlueprintMetadataMBean.SERVICE_MATADATA))
-			components = (ComponentMetadata [])container.getMetadata(ServiceMetadata.class).toArray();
-		else if(type.equals(BlueprintMetadataMBean.BEAN_METADATA))
-			components = (ComponentMetadata [])container.getMetadata(BeanMetadata.class).toArray();
-		else if(type.equals(BlueprintMetadataMBean.SERVICE_REFERENCE_METADATA))
-			components = (ComponentMetadata [])container.getMetadata(ServiceReferenceMetadata.class).toArray();
-		else 
-			throw new IllegalArgumentException(); 
-		String ids [] = new String[components.length];
-		for(int i=0;i<components.length;i++)
-		{
-			ids[i] = components[i].getId();
-		}
-		return ids;//(String [])container.getMetadata(type).toArray();
-	}
-
-	public byte[] getComponentMetadata(long containerServiceId,
-			String componentId) {
-		String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
-		ServiceReference [] serviceReferences = null;
-		try {
-			serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
-		} catch (InvalidSyntaxException e) {
-			throw new RuntimeException(e);
-		}
-		if(serviceReferences == null)
-			return null;
-		BlueprintContainer container = (BlueprintContainer)bundleContext.getService(serviceReferences[0]);
-		ComponentMetadata componentMetadata = container.getComponentMetadata(componentId);
-		BPMetadata metadata = Util.metadata2BPMetadata(componentMetadata);
-		return Util.bpMetadata2Binary(metadata);
-	}
+    BundleContext bundleContext;
+
+    public BlueprintMetadata(BundleContext bundleContext) {
+        this.bundleContext = bundleContext;
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean#getBlueprintContainerServiceId(long)
+     */
+    public long getBlueprintContainerServiceId(long bundleId) throws IOException {
+        Bundle bpBundle = bundleContext.getBundle(bundleId);
+
+        String filter = "(&(osgi.blueprint.container.symbolicname=" // no similar one in interfaces
+                + bpBundle.getSymbolicName() + ")(osgi.blueprint.container.version=" + bpBundle.getVersion() + "))";
+        ServiceReference[] serviceReferences = null;
+        try {
+            serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
+        } catch (InvalidSyntaxException e) {
+            throw new RuntimeException(e);
+        }
+        if (serviceReferences != null)
+            return (Long) serviceReferences[0].getProperty(Constants.SERVICE_ID);
+        else
+            return -1;
+    }
+
+    public long[] getBlueprintContainerServiceIds() throws IOException {
+        ServiceReference[] serviceReferences = null;
+        try {
+            serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), null);
+        } catch (InvalidSyntaxException e) {
+        }
+        long[] serviceIds = new long[serviceReferences.length];
+        for (int i = 0; i < serviceReferences.length; i++) {
+            serviceIds[i] = (Long) serviceReferences[i].getProperty(Constants.SERVICE_ID);
+        }
+        return serviceIds;
+    }
+
+    public String[] getComponentIds(long containerServiceId) {
+        String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
+        ServiceReference[] serviceReferences = null;
+        try {
+            serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
+        } catch (InvalidSyntaxException e) {
+            throw new RuntimeException(e);
+        }
+        if (serviceReferences == null)
+            return null;
+        BlueprintContainer container = (BlueprintContainer) bundleContext.getService(serviceReferences[0]);
+        return (String[]) container.getComponentIds().toArray();
+    }
+
+    /*
+     * 
+     * type could be Bean, Service, serviceReference (non-Javadoc)
+     * 
+     * @see org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean#getComponentIdsByType(long, java.lang.String)
+     */
+    public String[] getComponentIdsByType(long containerServiceId, String type) {
+        String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
+        ServiceReference[] serviceReferences = null;
+        try {
+            serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
+        } catch (InvalidSyntaxException e) {
+            throw new RuntimeException(e);
+        }
+        if (serviceReferences == null)
+            return null;
+        BlueprintContainer container = (BlueprintContainer) bundleContext.getService(serviceReferences[0]);
+        ComponentMetadata[] components;
+        if (type.equals(BlueprintMetadataMBean.SERVICE_MATADATA))
+            components = (ComponentMetadata[]) container.getMetadata(ServiceMetadata.class).toArray();
+        else if (type.equals(BlueprintMetadataMBean.BEAN_METADATA))
+            components = (ComponentMetadata[]) container.getMetadata(BeanMetadata.class).toArray();
+        else if (type.equals(BlueprintMetadataMBean.SERVICE_REFERENCE_METADATA))
+            components = (ComponentMetadata[]) container.getMetadata(ServiceReferenceMetadata.class).toArray();
+        else
+            throw new IllegalArgumentException();
+        String ids[] = new String[components.length];
+        for (int i = 0; i < components.length; i++) {
+            ids[i] = components[i].getId();
+        }
+        return ids;// (String [])container.getMetadata(type).toArray();
+    }
+
+    public byte[] getComponentMetadata(long containerServiceId, String componentId) {
+        String filter = "(" + Constants.SERVICE_ID + "=" + containerServiceId + ")";
+        ServiceReference[] serviceReferences = null;
+        try {
+            serviceReferences = bundleContext.getServiceReferences(BlueprintContainer.class.getName(), filter);
+        } catch (InvalidSyntaxException e) {
+            throw new RuntimeException(e);
+        }
+        if (serviceReferences == null)
+            return null;
+        BlueprintContainer container = (BlueprintContainer) bundleContext.getService(serviceReferences[0]);
+        ComponentMetadata componentMetadata = container.getComponentMetadata(componentId);
+        BPMetadata metadata = Util.metadata2BPMetadata(componentMetadata);
+        return Util.bpMetadata2Binary(metadata);
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java Wed Nov 25 06:46:13 2009
@@ -9,56 +9,50 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.BeanArgument;
 
-public class BPBeanArgument implements TransferObject
-{
-	private int index;
-	
-	private BPMetadata value;
-	
-	private String valueType;   
-	
-	public BPBeanArgument(CompositeData argument)
-	{
-		index = (Integer)argument.get(BlueprintMetadataMBean.INDEX);
-		byte [] buf = (byte [])argument.get(BlueprintMetadataMBean.VALUE);
-		value = Util.binary2BPMetadata(buf);
-		valueType  = (String)argument.get(BlueprintMetadataMBean.VALUE_TYPE);
-	}
-	public BPBeanArgument(BeanArgument argument)
-	{
-		index = argument.getIndex();
-		
-		value = Util.metadata2BPMetadata(argument.getValue());
-		
-		valueType = argument.getValueType();
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.INDEX, index);
-		items.put(BlueprintMetadataMBean.VALUE, Util.bpMetadata2Binary(value));
-		items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.BEAN_PROPERTY_TYPE,
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	public int getIndex()
-	{
-		return index;
-	}
-	
-	public BPMetadata getValue()
-	{
-		return value;
-	}
-	
-	public String getValueType()
-	{
-		return valueType;
-	}
+public class BPBeanArgument implements TransferObject {
+    private int index;
+
+    private BPMetadata value;
+
+    private String valueType;
+
+    public BPBeanArgument(CompositeData argument) {
+        index = (Integer) argument.get(BlueprintMetadataMBean.INDEX);
+        byte[] buf = (byte[]) argument.get(BlueprintMetadataMBean.VALUE);
+        value = Util.binary2BPMetadata(buf);
+        valueType = (String) argument.get(BlueprintMetadataMBean.VALUE_TYPE);
+    }
+
+    public BPBeanArgument(BeanArgument argument) {
+        index = argument.getIndex();
+
+        value = Util.metadata2BPMetadata(argument.getValue());
+
+        valueType = argument.getValueType();
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.INDEX, index);
+        items.put(BlueprintMetadataMBean.VALUE, Util.bpMetadata2Binary(value));
+        items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.BEAN_PROPERTY_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public int getIndex() {
+        return index;
+    }
+
+    public BPMetadata getValue() {
+        return value;
+    }
+
+    public String getValueType() {
+        return valueType;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java Wed Nov 25 06:46:13 2009
@@ -11,147 +11,136 @@
 import org.osgi.service.blueprint.reflect.BeanMetadata;
 import org.osgi.service.blueprint.reflect.BeanProperty;
 
-public class BPBeanMetadata extends BPComponentMetadata implements BPTarget, TransferObject
-{
-	
-	private String className;
-	
-	private String destroyMethod;
-	
-	private String factoryMethod;
-	
-	private String initMethod;
-	
-	private String scope;
-	
-	private BPBeanArgument [] arguments;
-	
-	private BPBeanProperty [] properties;
-	
-	private BPTarget factoryComponent;
-	
-	public BPBeanMetadata(CompositeData bean)
-	{
-		super(bean);
-		className = (String)bean.get(BlueprintMetadataMBean.CLASS_NAME);
-		destroyMethod = (String)bean.get(BlueprintMetadataMBean.DESTROY_METHOD);
-		factoryMethod = (String)bean.get(BlueprintMetadataMBean.FACTORY_METHOD);
-		initMethod = (String)bean.get(BlueprintMetadataMBean.INIT_METHOD);
-		scope = (String)bean.get(BlueprintMetadataMBean.SCOPE);
-		
-		byte [] buf = (byte [])bean.get(BlueprintMetadataMBean.FACTORY_COMPONENT);
-		factoryComponent = (BPTarget)Util.binary2BPMetadata(buf);
-		
-		CompositeData [] cd_args = (CompositeData [])bean.get(BlueprintMetadataMBean.ARGUMENTS);
-		arguments = new BPBeanArgument[cd_args.length];
-		for(int i=0;i<arguments.length;i++)
-		{
-			arguments[i] = new BPBeanArgument(cd_args[i]);
-		}
-		
-		CompositeData [] cd_props = (CompositeData [])bean.get(BlueprintMetadataMBean.PROPERTIES);
-		properties = new BPBeanProperty[cd_props.length];
-		for(int i=0;i<properties.length;i++)
-		{
-			properties[i] = new BPBeanProperty(cd_props[i]);
-		}
-		
-	}
-	public BPBeanMetadata(BeanMetadata bean)
-	{
-		super(bean);
-		className = bean.getClassName();
-		destroyMethod = bean.getDestroyMethod();
-		factoryMethod = bean.getFactoryMethod();
-		initMethod = bean.getInitMethod();
-		scope = bean.getScope();
-		
-		factoryComponent = (BPTarget)Util.metadata2BPMetadata(bean.getFactoryComponent());
-		
-		arguments = new BPBeanArgument[bean.getArguments().size()];
-		int i=0;
-		for(Object arg : bean.getArguments())
-		{
-			arguments[i++] = new BPBeanArgument((BeanArgument)arg);
-		}
-		
-		properties = new BPBeanProperty[bean.getProperties().size()];
-		i=0;
-		for(Object prop: bean.getProperties())
-		{
-			properties[i++] = new BPBeanProperty((BeanProperty)prop);
-		}
-	}
-	protected Map<String, Object> getItemsMap()
-	{
-		Map<String, Object> items = super.getItemsMap();
-		
-		//add its fields to the map
-		items.put(BlueprintMetadataMBean.CLASS_NAME, className);
-		items.put(BlueprintMetadataMBean.DESTROY_METHOD, destroyMethod);
-		items.put(BlueprintMetadataMBean.FACTORY_METHOD, factoryMethod);
-		items.put(BlueprintMetadataMBean.INIT_METHOD, initMethod);
-		items.put(BlueprintMetadataMBean.SCOPE, scope);
-
-		items.put(BlueprintMetadataMBean.FACTORY_COMPONENT, 
-				Util.bpMetadata2Binary(factoryComponent));
-		
-		CompositeData [] cd_args = new CompositeData[arguments.length];
-		for(int i=0;i<arguments.length;i++)
-		{
-			cd_args[i] = arguments[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.ARGUMENTS, cd_args);
-		
-		CompositeData [] cd_props = new CompositeData[properties.length];
-		for(int i=0;i<properties.length;i++)
-		{
-			cd_props[i] = properties[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.PROPERTIES, cd_props);
-		
-		return items;
-	}
-	
-	public CompositeData asCompositeData()
-	{
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.BEAN_METADATA_TYPE,
-					getItemsMap());
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	
-	public BPBeanArgument [] getArguments() {
-		return arguments;
-	}
-	
-	public String getClassName() {
-		return className;
-	}
-
-	public String getDestroyMethod() {
-		return destroyMethod;
-	}
-	public BPTarget getFactoryComponent() {
-		return factoryComponent;
-	}
-
-	public String getFactoryMethod() {
-		return factoryMethod;
-	}
-	
-	public String getInitMethod() {
-		return initMethod;
-	}
-	
-	public BPBeanProperty [] getProperties() {
-		return properties;
-	}
-	
-	public String getScope() {
-		return scope;
-	}
+public class BPBeanMetadata extends BPComponentMetadata implements BPTarget, TransferObject {
+
+    private String className;
+
+    private String destroyMethod;
+
+    private String factoryMethod;
+
+    private String initMethod;
+
+    private String scope;
+
+    private BPBeanArgument[] arguments;
+
+    private BPBeanProperty[] properties;
+
+    private BPTarget factoryComponent;
+
+    public BPBeanMetadata(CompositeData bean) {
+        super(bean);
+        className = (String) bean.get(BlueprintMetadataMBean.CLASS_NAME);
+        destroyMethod = (String) bean.get(BlueprintMetadataMBean.DESTROY_METHOD);
+        factoryMethod = (String) bean.get(BlueprintMetadataMBean.FACTORY_METHOD);
+        initMethod = (String) bean.get(BlueprintMetadataMBean.INIT_METHOD);
+        scope = (String) bean.get(BlueprintMetadataMBean.SCOPE);
+
+        byte[] buf = (byte[]) bean.get(BlueprintMetadataMBean.FACTORY_COMPONENT);
+        factoryComponent = (BPTarget) Util.binary2BPMetadata(buf);
+
+        CompositeData[] cd_args = (CompositeData[]) bean.get(BlueprintMetadataMBean.ARGUMENTS);
+        arguments = new BPBeanArgument[cd_args.length];
+        for (int i = 0; i < arguments.length; i++) {
+            arguments[i] = new BPBeanArgument(cd_args[i]);
+        }
+
+        CompositeData[] cd_props = (CompositeData[]) bean.get(BlueprintMetadataMBean.PROPERTIES);
+        properties = new BPBeanProperty[cd_props.length];
+        for (int i = 0; i < properties.length; i++) {
+            properties[i] = new BPBeanProperty(cd_props[i]);
+        }
+
+    }
+
+    public BPBeanMetadata(BeanMetadata bean) {
+        super(bean);
+        className = bean.getClassName();
+        destroyMethod = bean.getDestroyMethod();
+        factoryMethod = bean.getFactoryMethod();
+        initMethod = bean.getInitMethod();
+        scope = bean.getScope();
+
+        factoryComponent = (BPTarget) Util.metadata2BPMetadata(bean.getFactoryComponent());
+
+        arguments = new BPBeanArgument[bean.getArguments().size()];
+        int i = 0;
+        for (Object arg : bean.getArguments()) {
+            arguments[i++] = new BPBeanArgument((BeanArgument) arg);
+        }
+
+        properties = new BPBeanProperty[bean.getProperties().size()];
+        i = 0;
+        for (Object prop : bean.getProperties()) {
+            properties[i++] = new BPBeanProperty((BeanProperty) prop);
+        }
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        Map<String, Object> items = super.getItemsMap();
+
+        // add its fields to the map
+        items.put(BlueprintMetadataMBean.CLASS_NAME, className);
+        items.put(BlueprintMetadataMBean.DESTROY_METHOD, destroyMethod);
+        items.put(BlueprintMetadataMBean.FACTORY_METHOD, factoryMethod);
+        items.put(BlueprintMetadataMBean.INIT_METHOD, initMethod);
+        items.put(BlueprintMetadataMBean.SCOPE, scope);
+
+        items.put(BlueprintMetadataMBean.FACTORY_COMPONENT, Util.bpMetadata2Binary(factoryComponent));
+
+        CompositeData[] cd_args = new CompositeData[arguments.length];
+        for (int i = 0; i < arguments.length; i++) {
+            cd_args[i] = arguments[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.ARGUMENTS, cd_args);
+
+        CompositeData[] cd_props = new CompositeData[properties.length];
+        for (int i = 0; i < properties.length; i++) {
+            cd_props[i] = properties[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.PROPERTIES, cd_props);
+
+        return items;
+    }
+
+    public CompositeData asCompositeData() {
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.BEAN_METADATA_TYPE, getItemsMap());
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public BPBeanArgument[] getArguments() {
+        return arguments;
+    }
+
+    public String getClassName() {
+        return className;
+    }
+
+    public String getDestroyMethod() {
+        return destroyMethod;
+    }
+
+    public BPTarget getFactoryComponent() {
+        return factoryComponent;
+    }
+
+    public String getFactoryMethod() {
+        return factoryMethod;
+    }
+
+    public String getInitMethod() {
+        return initMethod;
+    }
+
+    public BPBeanProperty[] getProperties() {
+        return properties;
+    }
+
+    public String getScope() {
+        return scope;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java Wed Nov 25 06:46:13 2009
@@ -9,45 +9,40 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.BeanProperty;
 
-public class BPBeanProperty implements TransferObject
-{
-	private String name;   
+public class BPBeanProperty implements TransferObject {
+    private String name;
     private BPMetadata value;
-	
-	public BPBeanProperty(CompositeData property)
-	{
-		name = (String)property.get(BlueprintMetadataMBean.NAME);
-		
-		byte [] buf = (byte [])property.get(BlueprintMetadataMBean.VALUE);
-		value = Util.binary2BPMetadata(buf);
-	}
-	public BPBeanProperty(BeanProperty property)
-	{
-		name = property.getName();
-		
-		value = Util.metadata2BPMetadata(property.getValue());
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.NAME, name);
-		items.put(BlueprintMetadataMBean.VALUE, 
-				Util.bpMetadata2Binary(value));
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.BEAN_ARGUMENT_TYPE,
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public String getName() {
-		return name;
-	}
-
-	public BPMetadata getValue() {
-		return value;
-	}
+
+    public BPBeanProperty(CompositeData property) {
+        name = (String) property.get(BlueprintMetadataMBean.NAME);
+
+        byte[] buf = (byte[]) property.get(BlueprintMetadataMBean.VALUE);
+        value = Util.binary2BPMetadata(buf);
+    }
+
+    public BPBeanProperty(BeanProperty property) {
+        name = property.getName();
+
+        value = Util.metadata2BPMetadata(property.getValue());
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.NAME, name);
+        items.put(BlueprintMetadataMBean.VALUE, Util.bpMetadata2Binary(value));
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.BEAN_ARGUMENT_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public BPMetadata getValue() {
+        return value;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java Wed Nov 25 06:46:13 2009
@@ -10,69 +10,62 @@
 import org.osgi.service.blueprint.reflect.CollectionMetadata;
 import org.osgi.service.blueprint.reflect.Metadata;
 
-public class BPCollectionMetadata implements BPNonNullMetadata, TransferObject
-{
-	private String collectionClass;
-	
-	private String valueType;
-	
-	private BPMetadata [] values;
-	
-	public BPCollectionMetadata(CompositeData collection)
-	{
-		collectionClass = (String)collection.get(BlueprintMetadataMBean.COLLECTION_CLASS);
-		valueType = (String)collection.get(BlueprintMetadataMBean.VALUE_TYPE);
-		
-		byte [][] arrays = (byte[][])collection.get(BlueprintMetadataMBean.VALUES);
-		values = new BPMetadata[arrays.length];
-		for(int i=0;i<values.length;i++)
-		{
-			values[i] = Util.binary2BPMetadata((byte [])arrays[i]);
-		}
-	}
-	public BPCollectionMetadata(CollectionMetadata collection)
-	{
-		collectionClass = collection.getCollectionClass().getCanonicalName();
-		valueType = collection.getValueType();
-		
-		values = new BPMetadata[collection.getValues().size()];
-		int i=0;
-		for(Object value : collection.getValues())
-		{
-			values[i++] = Util.metadata2BPMetadata((Metadata)value);
-		}
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.COLLECTION_CLASS, collectionClass);
-		items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
-		
-		byte [][] arrays = new byte[values.length][];
-		for(int i=0;i<arrays.length;i++)
-		{
-			arrays[i] = Util.bpMetadata2Binary(values[i]);
-		}
-		items.put(BlueprintMetadataMBean.VALUES, arrays);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.COLLECTION_METADATA_TYPE,
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	  
-	public String getCollectionClass() {
-		return collectionClass;
-	}
-	  
-	public String getValueType() {
-		return valueType;
-	}
-	  
-	public BPMetadata [] getValues() {
-		return values;
-	}
+public class BPCollectionMetadata implements BPNonNullMetadata, TransferObject {
+    private String collectionClass;
+
+    private String valueType;
+
+    private BPMetadata[] values;
+
+    public BPCollectionMetadata(CompositeData collection) {
+        collectionClass = (String) collection.get(BlueprintMetadataMBean.COLLECTION_CLASS);
+        valueType = (String) collection.get(BlueprintMetadataMBean.VALUE_TYPE);
+
+        byte[][] arrays = (byte[][]) collection.get(BlueprintMetadataMBean.VALUES);
+        values = new BPMetadata[arrays.length];
+        for (int i = 0; i < values.length; i++) {
+            values[i] = Util.binary2BPMetadata((byte[]) arrays[i]);
+        }
+    }
+
+    public BPCollectionMetadata(CollectionMetadata collection) {
+        collectionClass = collection.getCollectionClass().getCanonicalName();
+        valueType = collection.getValueType();
+
+        values = new BPMetadata[collection.getValues().size()];
+        int i = 0;
+        for (Object value : collection.getValues()) {
+            values[i++] = Util.metadata2BPMetadata((Metadata) value);
+        }
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.COLLECTION_CLASS, collectionClass);
+        items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
+
+        byte[][] arrays = new byte[values.length][];
+        for (int i = 0; i < arrays.length; i++) {
+            arrays[i] = Util.bpMetadata2Binary(values[i]);
+        }
+        items.put(BlueprintMetadataMBean.VALUES, arrays);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.COLLECTION_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getCollectionClass() {
+        return collectionClass;
+    }
+
+    public String getValueType() {
+        return valueType;
+    }
+
+    public BPMetadata[] getValues() {
+        return values;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java Wed Nov 25 06:46:13 2009
@@ -8,49 +8,44 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.ComponentMetadata;
 
-public class BPComponentMetadata implements BPNonNullMetadata
-{
-	private int activation;
-	
-	private String [] dependsOn;
-	
-	private String id;   
-	
-	@SuppressWarnings("boxing")
-	protected BPComponentMetadata(CompositeData component)
-	{
-		activation = (Integer)component.get(BlueprintMetadataMBean.ACTIVATION);
-		dependsOn = (String [])component.get(BlueprintMetadataMBean.DEPENDS_ON);
-		id = (String)component.get(BlueprintMetadataMBean.ID);
-	}
-	
-	protected BPComponentMetadata(ComponentMetadata component)
-	{
-		activation = component.getActivation();
-		dependsOn = (String [])component.getDependsOn().toArray();
-		id = (String)component.getId();
-	}
-	
-	protected Map<String, Object> getItemsMap()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.ACTIVATION, activation);
-		items.put(BlueprintMetadataMBean.DEPENDS_ON, dependsOn);
-		items.put(BlueprintMetadataMBean.ID, id);
-		
-		return items;
-	}
-	
-	public int getActivation() 
-	{
-		return activation;
-	}
-
-	public String [] getDependsOn() {
-		return dependsOn;
-	}
-
-	public String getId() {
-		return id;
-	}
+public class BPComponentMetadata implements BPNonNullMetadata {
+    private int activation;
+
+    private String[] dependsOn;
+
+    private String id;
+
+    @SuppressWarnings("boxing")
+    protected BPComponentMetadata(CompositeData component) {
+        activation = (Integer) component.get(BlueprintMetadataMBean.ACTIVATION);
+        dependsOn = (String[]) component.get(BlueprintMetadataMBean.DEPENDS_ON);
+        id = (String) component.get(BlueprintMetadataMBean.ID);
+    }
+
+    protected BPComponentMetadata(ComponentMetadata component) {
+        activation = component.getActivation();
+        dependsOn = (String[]) component.getDependsOn().toArray();
+        id = (String) component.getId();
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.ACTIVATION, activation);
+        items.put(BlueprintMetadataMBean.DEPENDS_ON, dependsOn);
+        items.put(BlueprintMetadataMBean.ID, id);
+
+        return items;
+    }
+
+    public int getActivation() {
+        return activation;
+    }
+
+    public String[] getDependsOn() {
+        return dependsOn;
+    }
+
+    public String getId() {
+        return id;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java Wed Nov 25 06:46:13 2009
@@ -9,32 +9,29 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.IdRefMetadata;
 
-public class BPIdRefMetadata implements BPNonNullMetadata, TransferObject
-{ 
-	private String componentId;
-	public BPIdRefMetadata(CompositeData idRef)
-	{
-		componentId = (String)idRef.get(BlueprintMetadataMBean.COMPONENT_ID);
-	}
-	public BPIdRefMetadata(IdRefMetadata idRef)
-	{
-		componentId = idRef.getComponentId();
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.COMPONENT_ID, componentId);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.ID_REF_METADATA_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public String getComponentId() {
-		return componentId;
-	}
+public class BPIdRefMetadata implements BPNonNullMetadata, TransferObject {
+    private String componentId;
+
+    public BPIdRefMetadata(CompositeData idRef) {
+        componentId = (String) idRef.get(BlueprintMetadataMBean.COMPONENT_ID);
+    }
+
+    public BPIdRefMetadata(IdRefMetadata idRef) {
+        componentId = idRef.getComponentId();
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.COMPONENT_ID, componentId);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.ID_REF_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getComponentId() {
+        return componentId;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java Wed Nov 25 06:46:13 2009
@@ -9,46 +9,41 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.MapEntry;
 
-public class BPMapEntry implements TransferObject
-{
-	private BPNonNullMetadata key;
-	
-	private BPMetadata value;
-	
-	public BPMapEntry(CompositeData entry)
-	{
-		byte [] buf = (byte [])entry.get(BlueprintMetadataMBean.KEY);
-		key = (BPNonNullMetadata)Util.binary2BPMetadata(buf);
-		
-		buf = (byte [])entry.get(BlueprintMetadataMBean.VALUE);
-		value = Util.binary2BPMetadata(buf);
-	}
-	public BPMapEntry(MapEntry entry)
-	{
-		key = (BPNonNullMetadata)Util.metadata2BPMetadata(entry.getKey());
-		value = Util.metadata2BPMetadata(entry.getValue());
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.KEY, key);
-		items.put(BlueprintMetadataMBean.VALUE, 
-				Util.bpMetadata2Binary(value));
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.MAP_ENTRY_TYPE,
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	  
-	public BPNonNullMetadata getKey() {
-		return key;
-	}
-	  
-	public BPMetadata getValue() {
-		return value;
-	}
+public class BPMapEntry implements TransferObject {
+    private BPNonNullMetadata key;
+
+    private BPMetadata value;
+
+    public BPMapEntry(CompositeData entry) {
+        byte[] buf = (byte[]) entry.get(BlueprintMetadataMBean.KEY);
+        key = (BPNonNullMetadata) Util.binary2BPMetadata(buf);
+
+        buf = (byte[]) entry.get(BlueprintMetadataMBean.VALUE);
+        value = Util.binary2BPMetadata(buf);
+    }
+
+    public BPMapEntry(MapEntry entry) {
+        key = (BPNonNullMetadata) Util.metadata2BPMetadata(entry.getKey());
+        value = Util.metadata2BPMetadata(entry.getValue());
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.KEY, key);
+        items.put(BlueprintMetadataMBean.VALUE, Util.bpMetadata2Binary(value));
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.MAP_ENTRY_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public BPNonNullMetadata getKey() {
+        return key;
+    }
+
+    public BPMetadata getValue() {
+        return value;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java Wed Nov 25 06:46:13 2009
@@ -10,70 +10,62 @@
 import org.osgi.service.blueprint.reflect.MapEntry;
 import org.osgi.service.blueprint.reflect.MapMetadata;
 
-public class BPMapMetadata implements BPNonNullMetadata, TransferObject
-{
-	private String keyType;
-	
-	private String valueType;
-	
-	private BPMapEntry [] entries;
-	
-	public BPMapMetadata(CompositeData map)
-	{
-		keyType = (String)map.get(BlueprintMetadataMBean.KEY_TYPE);
-		valueType = (String)map.get(BlueprintMetadataMBean.VALUE_TYPE);
-		
-		CompositeData [] cd_entries = (CompositeData [])map.get(
-				BlueprintMetadataMBean.ENTRIES);
-		entries = new BPMapEntry[cd_entries.length];
-		for(int i=0;i<entries.length;i++)
-		{
-			entries[i] = new BPMapEntry(cd_entries[i]);
-		}
-	}
-	public BPMapMetadata(MapMetadata map)
-	{
-		keyType = map.getKeyType();
-		valueType = map.getValueType();
-		
-		entries = new BPMapEntry[map.getEntries().size()];
-		int i=0;
-		for(Object arg : map.getEntries())
-		{
-			entries[i++] = new BPMapEntry((MapEntry)arg);
-		}
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.KEY_TYPE, keyType);
-		items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
-		
-		CompositeData [] cd_entries = new CompositeData[entries.length];
-		for(int i=0;i<entries.length;i++)
-		{
-			cd_entries[i] = entries[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.ENTRIES, cd_entries);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.MAP_METADATA_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	  
-	public BPMapEntry [] getEntries() {
-		return entries;
-	}
-	  
-	public String getKeyType() {
-		return keyType;
-	}
-	  
-	public String getValueType() {
-		return valueType;
-	}
+public class BPMapMetadata implements BPNonNullMetadata, TransferObject {
+    private String keyType;
+
+    private String valueType;
+
+    private BPMapEntry[] entries;
+
+    public BPMapMetadata(CompositeData map) {
+        keyType = (String) map.get(BlueprintMetadataMBean.KEY_TYPE);
+        valueType = (String) map.get(BlueprintMetadataMBean.VALUE_TYPE);
+
+        CompositeData[] cd_entries = (CompositeData[]) map.get(BlueprintMetadataMBean.ENTRIES);
+        entries = new BPMapEntry[cd_entries.length];
+        for (int i = 0; i < entries.length; i++) {
+            entries[i] = new BPMapEntry(cd_entries[i]);
+        }
+    }
+
+    public BPMapMetadata(MapMetadata map) {
+        keyType = map.getKeyType();
+        valueType = map.getValueType();
+
+        entries = new BPMapEntry[map.getEntries().size()];
+        int i = 0;
+        for (Object arg : map.getEntries()) {
+            entries[i++] = new BPMapEntry((MapEntry) arg);
+        }
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.KEY_TYPE, keyType);
+        items.put(BlueprintMetadataMBean.VALUE_TYPE, valueType);
+
+        CompositeData[] cd_entries = new CompositeData[entries.length];
+        for (int i = 0; i < entries.length; i++) {
+            cd_entries[i] = entries[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.ENTRIES, cd_entries);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.MAP_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public BPMapEntry[] getEntries() {
+        return entries;
+    }
+
+    public String getKeyType() {
+        return keyType;
+    }
+
+    public String getValueType() {
+        return valueType;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java Wed Nov 25 06:46:13 2009
@@ -1,5 +1,5 @@
 package org.apache.geronimo.blueprint.jmx.impl.codec;
 
 public interface BPMetadata {
-	// marker interface
+    // marker interface
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java Wed Nov 25 06:46:13 2009
@@ -1,5 +1,5 @@
 package org.apache.geronimo.blueprint.jmx.impl.codec;
 
-public interface BPNonNullMetadata extends BPMetadata{
-  //marker interface
+public interface BPNonNullMetadata extends BPMetadata {
+    // marker interface
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java Wed Nov 25 06:46:13 2009
@@ -4,9 +4,14 @@
 
 import org.osgi.service.blueprint.reflect.NullMetadata;
 
-public class BPNullMetadata implements BPMetadata, TransferObject
-{
-	public BPNullMetadata(CompositeData component){}
-	public BPNullMetadata(NullMetadata component){}
-	public CompositeData asCompositeData(){return null;}
+public class BPNullMetadata implements BPMetadata, TransferObject {
+    public BPNullMetadata(CompositeData component) {
+    }
+
+    public BPNullMetadata(NullMetadata component) {
+    }
+
+    public CompositeData asCompositeData() {
+        return null;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java Wed Nov 25 06:46:13 2009
@@ -10,48 +10,41 @@
 import org.osgi.service.blueprint.reflect.MapEntry;
 import org.osgi.service.blueprint.reflect.PropsMetadata;
 
-public class BPPropsMetadata implements BPNonNullMetadata, TransferObject
-{
-	BPMapEntry [] entries;
-	public BPPropsMetadata(CompositeData props)
-	{
-		CompositeData [] cd_entries = (CompositeData [])props.get(
-				BlueprintMetadataMBean.ENTRIES);
-		entries = new BPMapEntry[cd_entries.length];
-		for(int i=0;i<entries.length;i++)
-		{
-			entries[i] = new BPMapEntry(cd_entries[i]);
-		}
-	}
-	public BPPropsMetadata(PropsMetadata props)
-	{
-		entries = new BPMapEntry[props.getEntries().size()];
-		int i=0;
-		for(Object arg : props.getEntries())
-		{
-			entries[i++] = new BPMapEntry((MapEntry)arg);
-		}
-	}
-	public CompositeData asCompositeData()
-	{
-		CompositeData [] cd_entries = new CompositeData[entries.length];
-		for(int i=0;i<entries.length;i++)
-		{
-			cd_entries[i] = entries[i].asCompositeData();
-		}
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.ENTRIES, cd_entries);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.PROPS_METADATA_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	
-	public BPMapEntry [] getEntries() {
-		return entries;
-	}
+public class BPPropsMetadata implements BPNonNullMetadata, TransferObject {
+    BPMapEntry[] entries;
+
+    public BPPropsMetadata(CompositeData props) {
+        CompositeData[] cd_entries = (CompositeData[]) props.get(BlueprintMetadataMBean.ENTRIES);
+        entries = new BPMapEntry[cd_entries.length];
+        for (int i = 0; i < entries.length; i++) {
+            entries[i] = new BPMapEntry(cd_entries[i]);
+        }
+    }
+
+    public BPPropsMetadata(PropsMetadata props) {
+        entries = new BPMapEntry[props.getEntries().size()];
+        int i = 0;
+        for (Object arg : props.getEntries()) {
+            entries[i++] = new BPMapEntry((MapEntry) arg);
+        }
+    }
+
+    public CompositeData asCompositeData() {
+        CompositeData[] cd_entries = new CompositeData[entries.length];
+        for (int i = 0; i < entries.length; i++) {
+            cd_entries[i] = entries[i].asCompositeData();
+        }
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.ENTRIES, cd_entries);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.PROPS_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public BPMapEntry[] getEntries() {
+        return entries;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java Wed Nov 25 06:46:13 2009
@@ -9,32 +9,29 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.RefMetadata;
 
-public class BPRefMetadata implements BPNonNullMetadata, BPTarget, TransferObject
-{
-	private String componentId;
-	public BPRefMetadata(CompositeData ref)
-	{
-		componentId = (String)ref.get(BlueprintMetadataMBean.COMPONENT_ID);
-	}
-	public BPRefMetadata(RefMetadata ref)
-	{
-		componentId = ref.getComponentId();
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.COMPONENT_ID, componentId);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.REF_METADATA_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public String getComponentId() {
-		return componentId;
-	}
+public class BPRefMetadata implements BPNonNullMetadata, BPTarget, TransferObject {
+    private String componentId;
+
+    public BPRefMetadata(CompositeData ref) {
+        componentId = (String) ref.get(BlueprintMetadataMBean.COMPONENT_ID);
+    }
+
+    public BPRefMetadata(RefMetadata ref) {
+        componentId = ref.getComponentId();
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.COMPONENT_ID, componentId);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.REF_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getComponentId() {
+        return componentId;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java Wed Nov 25 06:46:13 2009
@@ -9,40 +9,35 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.ReferenceListMetadata;
 
-public class BPReferenceListMetadata extends BPServiceReferenceMetadata 
-                                     implements TransferObject
-{
-	private int memberType;   
-	
-	public BPReferenceListMetadata(CompositeData ref_list)
-	{
-		super(ref_list);
-		memberType = (Integer)ref_list.get(BlueprintMetadataMBean.MEMBER_TYPE);
-	}
-	public BPReferenceListMetadata(ReferenceListMetadata ref_list)
-	{
-		super(ref_list);
-		memberType = ref_list.getMemberType();
-	}
-	protected Map<String, Object> getItemsMap()
-	{
-		Map<String, Object> items = super.getItemsMap();
-		items.put(BlueprintMetadataMBean.MEMBER_TYPE, memberType);
-		
-		return items;
-	}
-	public CompositeData asCompositeData()
-	{
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.REFERENCE_LIST_METADATA_TYPE, 
-					getItemsMap());
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public int getMemberType() {
-		return memberType;
-	}
+public class BPReferenceListMetadata extends BPServiceReferenceMetadata implements TransferObject {
+    private int memberType;
+
+    public BPReferenceListMetadata(CompositeData ref_list) {
+        super(ref_list);
+        memberType = (Integer) ref_list.get(BlueprintMetadataMBean.MEMBER_TYPE);
+    }
+
+    public BPReferenceListMetadata(ReferenceListMetadata ref_list) {
+        super(ref_list);
+        memberType = ref_list.getMemberType();
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        Map<String, Object> items = super.getItemsMap();
+        items.put(BlueprintMetadataMBean.MEMBER_TYPE, memberType);
+
+        return items;
+    }
+
+    public CompositeData asCompositeData() {
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.REFERENCE_LIST_METADATA_TYPE, getItemsMap());
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public int getMemberType() {
+        return memberType;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java Wed Nov 25 06:46:13 2009
@@ -9,60 +9,51 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.ReferenceListener;
 
-public class BPReferenceListener implements TransferObject
-{
-	private String bindMethod;
-	
-	private String unbindMethod;
-	
-	private BPTarget listenerComponent;
-	
-	public BPReferenceListener(CompositeData listener)
-	{
-		bindMethod = (String)listener.get(
-				BlueprintMetadataMBean.BIND_METHOD);
-		unbindMethod = (String)listener.get(
-				BlueprintMetadataMBean.UNBIND_METHOD);
-		
-		byte [] buf = (byte[])listener.get(
-				BlueprintMetadataMBean.LISTENER_COMPONENT);
-		listenerComponent = (BPTarget)Util.binary2BPMetadata(buf);
-	}
-	public BPReferenceListener(ReferenceListener listener)
-	{
-		bindMethod = listener.getBindMethod();
-		unbindMethod = listener.getUnbindMethod();
-		
-		listenerComponent = (BPTarget)Util.metadata2BPMetadata(
-				listener.getListenerComponent()) ;
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.BIND_METHOD, bindMethod);
-		items.put(BlueprintMetadataMBean.UNBIND_METHOD, unbindMethod);
-		
-		items.put(BlueprintMetadataMBean.LISTENER_COMPONENT, 
-				Util.bpMetadata2Binary(listenerComponent));
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.REFERENCE_LISTENER_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	  
-	public String getBindMethod() {
-		return bindMethod;
-	}
-	  
-	public BPTarget getListenerComponent() {
-		return listenerComponent;
-	}
-	  
-	public String getUnbindMethod() {
-		return unbindMethod;
-	}
+public class BPReferenceListener implements TransferObject {
+    private String bindMethod;
+
+    private String unbindMethod;
+
+    private BPTarget listenerComponent;
+
+    public BPReferenceListener(CompositeData listener) {
+        bindMethod = (String) listener.get(BlueprintMetadataMBean.BIND_METHOD);
+        unbindMethod = (String) listener.get(BlueprintMetadataMBean.UNBIND_METHOD);
+
+        byte[] buf = (byte[]) listener.get(BlueprintMetadataMBean.LISTENER_COMPONENT);
+        listenerComponent = (BPTarget) Util.binary2BPMetadata(buf);
+    }
+
+    public BPReferenceListener(ReferenceListener listener) {
+        bindMethod = listener.getBindMethod();
+        unbindMethod = listener.getUnbindMethod();
+
+        listenerComponent = (BPTarget) Util.metadata2BPMetadata(listener.getListenerComponent());
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.BIND_METHOD, bindMethod);
+        items.put(BlueprintMetadataMBean.UNBIND_METHOD, unbindMethod);
+
+        items.put(BlueprintMetadataMBean.LISTENER_COMPONENT, Util.bpMetadata2Binary(listenerComponent));
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.REFERENCE_LISTENER_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getBindMethod() {
+        return bindMethod;
+    }
+
+    public BPTarget getListenerComponent() {
+        return listenerComponent;
+    }
+
+    public String getUnbindMethod() {
+        return unbindMethod;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java Wed Nov 25 06:46:13 2009
@@ -9,40 +9,36 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.ReferenceMetadata;
 
-public class BPReferenceMetadata extends BPServiceReferenceMetadata implements BPTarget, TransferObject
-{
-	
-	private long timeout;  
-	
-	public BPReferenceMetadata(CompositeData reference)
-	{
-		super(reference);
-		timeout = (Long)reference.get(BlueprintMetadataMBean.TIMEOUT);
-	}
-	public BPReferenceMetadata(ReferenceMetadata reference)
-	{
-		super(reference);
-		timeout = reference.getTimeout();
-	}
-	protected Map<String, Object> getItemsMap()
-	{
-		Map<String, Object> items = super.getItemsMap();
-		items.put(BlueprintMetadataMBean.TIMEOUT, timeout);
-		
-		return items;
-	}
-	public CompositeData asCompositeData()
-	{
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.REFERENCE_METADATA_TYPE, 
-					getItemsMap());
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public long getTimeout() {
-		return timeout;
-	}
+public class BPReferenceMetadata extends BPServiceReferenceMetadata implements BPTarget, TransferObject {
+
+    private long timeout;
+
+    public BPReferenceMetadata(CompositeData reference) {
+        super(reference);
+        timeout = (Long) reference.get(BlueprintMetadataMBean.TIMEOUT);
+    }
+
+    public BPReferenceMetadata(ReferenceMetadata reference) {
+        super(reference);
+        timeout = reference.getTimeout();
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        Map<String, Object> items = super.getItemsMap();
+        items.put(BlueprintMetadataMBean.TIMEOUT, timeout);
+
+        return items;
+    }
+
+    public CompositeData asCompositeData() {
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.REFERENCE_METADATA_TYPE, getItemsMap());
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public long getTimeout() {
+        return timeout;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java Wed Nov 25 06:46:13 2009
@@ -9,62 +9,51 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.RegistrationListener;
 
-public class BPRegistrationListener implements TransferObject
-{
-	private	BPTarget listenerComponent;
-	
-	private String registrationMethod;
-	
-	private String unregistrationMethod;
-	
-	public BPRegistrationListener(CompositeData listener)
-	{
-		registrationMethod = (String)listener.get(
-				BlueprintMetadataMBean.REGISTRATION_METHOD);
-		unregistrationMethod = (String)listener.get(
-				BlueprintMetadataMBean.UNREGISTRATION_METHOD);
-
-		byte [] buf = (byte[])listener.get(
-				BlueprintMetadataMBean.LISTENER_COMPONENT);
-		listenerComponent = (BPTarget)Util.binary2BPMetadata(buf);
-	}
-	public BPRegistrationListener(RegistrationListener listener)
-	{
-		registrationMethod = listener.getRegistrationMethod();
-		unregistrationMethod = listener.getUnregistrationMethod();
-
-		listenerComponent = (BPTarget)Util.metadata2BPMetadata(
-				listener.getListenerComponent()) ;
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.REGISTRATION_METHOD, 
-				registrationMethod);
-		items.put(BlueprintMetadataMBean.UNREGISTRATION_METHOD, 
-				unregistrationMethod);
-
-		items.put(BlueprintMetadataMBean.LISTENER_COMPONENT, 
-				Util.bpMetadata2Binary(listenerComponent));
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.REGISTRATION_LISTENER_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-	   
-	public BPTarget getListenerComponent() {
-		return listenerComponent;
-	}
-	   
-	public String getRegistrationMethod() {
-		return registrationMethod;
-	}
-	   
-	public String getUnregistrationMethod() {
-		return unregistrationMethod;
-	}
+public class BPRegistrationListener implements TransferObject {
+    private BPTarget listenerComponent;
+
+    private String registrationMethod;
+
+    private String unregistrationMethod;
+
+    public BPRegistrationListener(CompositeData listener) {
+        registrationMethod = (String) listener.get(BlueprintMetadataMBean.REGISTRATION_METHOD);
+        unregistrationMethod = (String) listener.get(BlueprintMetadataMBean.UNREGISTRATION_METHOD);
+
+        byte[] buf = (byte[]) listener.get(BlueprintMetadataMBean.LISTENER_COMPONENT);
+        listenerComponent = (BPTarget) Util.binary2BPMetadata(buf);
+    }
+
+    public BPRegistrationListener(RegistrationListener listener) {
+        registrationMethod = listener.getRegistrationMethod();
+        unregistrationMethod = listener.getUnregistrationMethod();
+
+        listenerComponent = (BPTarget) Util.metadata2BPMetadata(listener.getListenerComponent());
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.REGISTRATION_METHOD, registrationMethod);
+        items.put(BlueprintMetadataMBean.UNREGISTRATION_METHOD, unregistrationMethod);
+
+        items.put(BlueprintMetadataMBean.LISTENER_COMPONENT, Util.bpMetadata2Binary(listenerComponent));
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.REGISTRATION_LISTENER_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public BPTarget getListenerComponent() {
+        return listenerComponent;
+    }
+
+    public String getRegistrationMethod() {
+        return registrationMethod;
+    }
+
+    public String getUnregistrationMethod() {
+        return unregistrationMethod;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java Wed Nov 25 06:46:13 2009
@@ -11,125 +11,115 @@
 import org.osgi.service.blueprint.reflect.RegistrationListener;
 import org.osgi.service.blueprint.reflect.ServiceMetadata;
 
-public class BPServiceMetadata extends BPComponentMetadata 
-                               implements TransferObject 
-{
-
-	private int autoExport;
-
-	private String[] interfaces;
-
-	private int ranking;
-
-	private BPRegistrationListener[] listeners;
-
-	private BPMapEntry[] properties;
-
-	private BPTarget serviceComponent;
-
-	public BPServiceMetadata(CompositeData service) {
-		super(service);
-		autoExport = (Integer) service.get(
-				BlueprintMetadataMBean.AUTO_EXPORT);
-		interfaces = (String[]) service.get(
-				BlueprintMetadataMBean.INTERFACES);
-		ranking = (Integer) service.get(BlueprintMetadataMBean.RANKING);
-
-		CompositeData[] cd_listeners = (CompositeData[]) service
-				.get(BlueprintMetadataMBean.REGISTRATION_LISTENERS);
-		listeners = new BPRegistrationListener[cd_listeners.length];
-		for (int i = 0; i < listeners.length; i++) {
-			listeners[i] = new BPRegistrationListener(cd_listeners[i]);
-		}
-
-		CompositeData[] cd_props = (CompositeData[]) service
-				.get(BlueprintMetadataMBean.SERVICE_PROPERTIES);
-		properties = new BPMapEntry[cd_props.length];
-		for (int i = 0; i < properties.length; i++) {
-			properties[i] = new BPMapEntry(cd_props[i]);
-		}
-
-		byte [] buf = (byte [])service.get(BlueprintMetadataMBean.SERVICE_COMPONENT);
-		serviceComponent = (BPTarget)Util.binary2BPMetadata(buf);
-	}
-
-	public BPServiceMetadata(ServiceMetadata service) {
-		super(service);
-		autoExport = service.getAutoExport();
-		interfaces = (String[]) service.getInterfaces().toArray();
-		ranking = service.getRanking();
-
-		listeners = new BPRegistrationListener[service
-				.getRegistrationListeners().size()];
-		int i = 0;
-		for (Object listener : service.getRegistrationListeners()) {
-			listeners[i++] = new BPRegistrationListener(
-					(RegistrationListener) listener);
-		}
-
-		properties = new BPMapEntry[service.getServiceProperties().size()];
-		i = 0;
-		for (Object prop : service.getServiceProperties()) {
-			properties[i++] = new BPMapEntry((MapEntry) prop);
-		}
-		
-		serviceComponent = (BPTarget)Util.metadata2BPMetadata(service.getServiceComponent());
-	}
-
-	protected Map<String, Object> getItemsMap() {
-		Map<String, Object> items = super.getItemsMap();
-		items.put(BlueprintMetadataMBean.AUTO_EXPORT, autoExport);
-		items.put(BlueprintMetadataMBean.INTERFACES, interfaces);
-		items.put(BlueprintMetadataMBean.RANKING, ranking);
-
-		CompositeData[] cd_listeners = new CompositeData[listeners.length];
-		for (int i = 0; i < listeners.length; i++) {
-			cd_listeners[i] = listeners[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.REGISTRATION_LISTENERS, cd_listeners);
-
-		CompositeData[] cd_props = new CompositeData[properties.length];
-		for (int i = 0; i < properties.length; i++) {
-			cd_props[i] = properties[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.SERVICE_PROPERTIES, cd_props);
-		
-		items.put(BlueprintMetadataMBean.SERVICE_COMPONENT, 
-				Util.bpMetadata2Binary(serviceComponent));
-		
-		return items;
-	}
-
-	public CompositeData asCompositeData() {
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.SERVICE_MATADATA_TYPE, getItemsMap());
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public int getAutoExport() {
-		return autoExport;
-	}
-
-	public String[] getInterfaces() {
-		return interfaces;
-	}
-
-	public int getRanking() {
-		return ranking;
-	}
-
-	public BPRegistrationListener[] getRegistrationListeners() {
-		return listeners;
-	}
-
-	public BPTarget getServiceComponent() {
-		return serviceComponent;
-	}
-
-	public BPMapEntry[] getServiceProperties() {
-		return properties;
-	}
+public class BPServiceMetadata extends BPComponentMetadata implements TransferObject {
+
+    private int autoExport;
+
+    private String[] interfaces;
+
+    private int ranking;
+
+    private BPRegistrationListener[] listeners;
+
+    private BPMapEntry[] properties;
+
+    private BPTarget serviceComponent;
+
+    public BPServiceMetadata(CompositeData service) {
+        super(service);
+        autoExport = (Integer) service.get(BlueprintMetadataMBean.AUTO_EXPORT);
+        interfaces = (String[]) service.get(BlueprintMetadataMBean.INTERFACES);
+        ranking = (Integer) service.get(BlueprintMetadataMBean.RANKING);
+
+        CompositeData[] cd_listeners = (CompositeData[]) service.get(BlueprintMetadataMBean.REGISTRATION_LISTENERS);
+        listeners = new BPRegistrationListener[cd_listeners.length];
+        for (int i = 0; i < listeners.length; i++) {
+            listeners[i] = new BPRegistrationListener(cd_listeners[i]);
+        }
+
+        CompositeData[] cd_props = (CompositeData[]) service.get(BlueprintMetadataMBean.SERVICE_PROPERTIES);
+        properties = new BPMapEntry[cd_props.length];
+        for (int i = 0; i < properties.length; i++) {
+            properties[i] = new BPMapEntry(cd_props[i]);
+        }
+
+        byte[] buf = (byte[]) service.get(BlueprintMetadataMBean.SERVICE_COMPONENT);
+        serviceComponent = (BPTarget) Util.binary2BPMetadata(buf);
+    }
+
+    public BPServiceMetadata(ServiceMetadata service) {
+        super(service);
+        autoExport = service.getAutoExport();
+        interfaces = (String[]) service.getInterfaces().toArray();
+        ranking = service.getRanking();
+
+        listeners = new BPRegistrationListener[service.getRegistrationListeners().size()];
+        int i = 0;
+        for (Object listener : service.getRegistrationListeners()) {
+            listeners[i++] = new BPRegistrationListener((RegistrationListener) listener);
+        }
+
+        properties = new BPMapEntry[service.getServiceProperties().size()];
+        i = 0;
+        for (Object prop : service.getServiceProperties()) {
+            properties[i++] = new BPMapEntry((MapEntry) prop);
+        }
+
+        serviceComponent = (BPTarget) Util.metadata2BPMetadata(service.getServiceComponent());
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        Map<String, Object> items = super.getItemsMap();
+        items.put(BlueprintMetadataMBean.AUTO_EXPORT, autoExport);
+        items.put(BlueprintMetadataMBean.INTERFACES, interfaces);
+        items.put(BlueprintMetadataMBean.RANKING, ranking);
+
+        CompositeData[] cd_listeners = new CompositeData[listeners.length];
+        for (int i = 0; i < listeners.length; i++) {
+            cd_listeners[i] = listeners[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.REGISTRATION_LISTENERS, cd_listeners);
+
+        CompositeData[] cd_props = new CompositeData[properties.length];
+        for (int i = 0; i < properties.length; i++) {
+            cd_props[i] = properties[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.SERVICE_PROPERTIES, cd_props);
+
+        items.put(BlueprintMetadataMBean.SERVICE_COMPONENT, Util.bpMetadata2Binary(serviceComponent));
+
+        return items;
+    }
+
+    public CompositeData asCompositeData() {
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.SERVICE_MATADATA_TYPE, getItemsMap());
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public int getAutoExport() {
+        return autoExport;
+    }
+
+    public String[] getInterfaces() {
+        return interfaces;
+    }
+
+    public int getRanking() {
+        return ranking;
+    }
+
+    public BPRegistrationListener[] getRegistrationListeners() {
+        return listeners;
+    }
+
+    public BPTarget getServiceComponent() {
+        return serviceComponent;
+    }
+
+    public BPMapEntry[] getServiceProperties() {
+        return properties;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java Wed Nov 25 06:46:13 2009
@@ -10,84 +10,80 @@
 
 public class BPServiceReferenceMetadata extends BPComponentMetadata// implements ServiceReferenceMetadata
 {
-	
-	private int availability;
-	
-	private String componentName;
-	
-	private String filter;
-	
-	private String $interface;
-	
-	private BPReferenceListener [] listeners;
-	
-	protected BPServiceReferenceMetadata(CompositeData reference)
-	{
-		super(reference);
-		availability = (Integer)reference.get(BlueprintMetadataMBean.AVAILABILITY);
-		componentName = (String)reference.get(BlueprintMetadataMBean.DESTROY_METHOD);
-		filter = (String)reference.get(BlueprintMetadataMBean.FACTORY_METHOD);
-		$interface = (String)reference.get(BlueprintMetadataMBean.INIT_METHOD);
-		
-		CompositeData [] cd_listeners = (CompositeData [])reference.get(BlueprintMetadataMBean.REFERENCE_LISTENERS);
-		listeners = new BPReferenceListener[cd_listeners.length];
-		for(int i=0;i<listeners.length;i++)
-		{
-			listeners[i] = new BPReferenceListener(cd_listeners[i]);
-		}
-	}
-	protected BPServiceReferenceMetadata(ServiceReferenceMetadata reference)
-	{
-		super(reference);
-		availability = reference.getAvailability();
-		componentName = reference.getComponentName();
-		filter = reference.getFilter();
-		$interface = reference.getInterface();
-		
-		listeners = new BPReferenceListener[reference.getReferenceListeners().size()];
-		int i=0;
-		for(Object listener : reference.getReferenceListeners())
-		{
-			listeners[i++] = new BPReferenceListener((ReferenceListener)listener);
-		}
-	}
-	protected Map<String, Object> getItemsMap()
-	{
-		Map<String, Object> items = super.getItemsMap();
-		
-		//itself
-		items.put(BlueprintMetadataMBean.AVAILABILITY, availability);
-		items.put(BlueprintMetadataMBean.COMPONENT_NAME, componentName);
-		items.put(BlueprintMetadataMBean.FILTER, filter);
-		items.put(BlueprintMetadataMBean.INTERFACE, $interface);
-		
-		CompositeData [] cd_listeners = new CompositeData[listeners.length];
-		for(int i=0;i<listeners.length;i++)
-		{
-			cd_listeners[i] = listeners[i].asCompositeData();
-		}
-		items.put(BlueprintMetadataMBean.ARGUMENTS, cd_listeners);
-		
-		return items;
-	}
-	
-	public int getAvailability() {
-		return availability;
-	}
-	
-	public String getComponentName() {
-		return componentName;
-	}
-	  
-	public String getFilter() {
-		return filter;
-	}
-	  
-	public String getInterface() {
-		return $interface;
-	}
-	  
-	public BPReferenceListener [] getReferenceListeners() {
-		return listeners;
-	}
+
+    private int availability;
+
+    private String componentName;
+
+    private String filter;
+
+    private String $interface;
+
+    private BPReferenceListener[] listeners;
+
+    protected BPServiceReferenceMetadata(CompositeData reference) {
+        super(reference);
+        availability = (Integer) reference.get(BlueprintMetadataMBean.AVAILABILITY);
+        componentName = (String) reference.get(BlueprintMetadataMBean.DESTROY_METHOD);
+        filter = (String) reference.get(BlueprintMetadataMBean.FACTORY_METHOD);
+        $interface = (String) reference.get(BlueprintMetadataMBean.INIT_METHOD);
+
+        CompositeData[] cd_listeners = (CompositeData[]) reference.get(BlueprintMetadataMBean.REFERENCE_LISTENERS);
+        listeners = new BPReferenceListener[cd_listeners.length];
+        for (int i = 0; i < listeners.length; i++) {
+            listeners[i] = new BPReferenceListener(cd_listeners[i]);
+        }
+    }
+
+    protected BPServiceReferenceMetadata(ServiceReferenceMetadata reference) {
+        super(reference);
+        availability = reference.getAvailability();
+        componentName = reference.getComponentName();
+        filter = reference.getFilter();
+        $interface = reference.getInterface();
+
+        listeners = new BPReferenceListener[reference.getReferenceListeners().size()];
+        int i = 0;
+        for (Object listener : reference.getReferenceListeners()) {
+            listeners[i++] = new BPReferenceListener((ReferenceListener) listener);
+        }
+    }
+
+    protected Map<String, Object> getItemsMap() {
+        Map<String, Object> items = super.getItemsMap();
+
+        // itself
+        items.put(BlueprintMetadataMBean.AVAILABILITY, availability);
+        items.put(BlueprintMetadataMBean.COMPONENT_NAME, componentName);
+        items.put(BlueprintMetadataMBean.FILTER, filter);
+        items.put(BlueprintMetadataMBean.INTERFACE, $interface);
+
+        CompositeData[] cd_listeners = new CompositeData[listeners.length];
+        for (int i = 0; i < listeners.length; i++) {
+            cd_listeners[i] = listeners[i].asCompositeData();
+        }
+        items.put(BlueprintMetadataMBean.ARGUMENTS, cd_listeners);
+
+        return items;
+    }
+
+    public int getAvailability() {
+        return availability;
+    }
+
+    public String getComponentName() {
+        return componentName;
+    }
+
+    public String getFilter() {
+        return filter;
+    }
+
+    public String getInterface() {
+        return $interface;
+    }
+
+    public BPReferenceListener[] getReferenceListeners() {
+        return listeners;
+    }
 }

Modified: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java?rev=883992&r1=883991&r2=883992&view=diff
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java (original)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java Wed Nov 25 06:46:13 2009
@@ -9,42 +9,38 @@
 import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
 import org.osgi.service.blueprint.reflect.ValueMetadata;
 
-public class BPValueMetadata implements BPNonNullMetadata, TransferObject
-{ 
-	private String stringValue;
-	
-	private String type;
-	
-	public BPValueMetadata(CompositeData value)
-	{
-		stringValue = (String)value.get(BlueprintMetadataMBean.STRING_VALUE);
-		type = (String)value.get(BlueprintMetadataMBean.TYPE);
-	}
-	public BPValueMetadata(ValueMetadata value)
-	{
-		stringValue = value.getStringValue();
-		type = value.getType();
-	}
-	public CompositeData asCompositeData()
-	{
-		HashMap<String, Object> items = new HashMap<String, Object>();
-		items.put(BlueprintMetadataMBean.STRING_VALUE, stringValue);
-		items.put(BlueprintMetadataMBean.TYPE, type);
-		
-		try {
-			return new CompositeDataSupport(
-					BlueprintMetadataMBean.VALUE_METADATA_TYPE, 
-					items);
-		} catch (OpenDataException e) {
-			throw new RuntimeException(e);
-		}
-	}
-
-	public String getStringValue() {
-		return stringValue;
-	}
-
-	public String getType() {
-		return type;
-	}
+public class BPValueMetadata implements BPNonNullMetadata, TransferObject {
+    private String stringValue;
+
+    private String type;
+
+    public BPValueMetadata(CompositeData value) {
+        stringValue = (String) value.get(BlueprintMetadataMBean.STRING_VALUE);
+        type = (String) value.get(BlueprintMetadataMBean.TYPE);
+    }
+
+    public BPValueMetadata(ValueMetadata value) {
+        stringValue = value.getStringValue();
+        type = value.getType();
+    }
+
+    public CompositeData asCompositeData() {
+        HashMap<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintMetadataMBean.STRING_VALUE, stringValue);
+        items.put(BlueprintMetadataMBean.TYPE, type);
+
+        try {
+            return new CompositeDataSupport(BlueprintMetadataMBean.VALUE_METADATA_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    public String getStringValue() {
+        return stringValue;
+    }
+
+    public String getType() {
+        return type;
+    }
 }



Mime
View raw message