geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwo...@apache.org
Subject svn commit: r883991 [1/2] - in /geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl: ./ src/ src/main/ src/main/java/ src/main/java/org/ src/main/java/org/apache/ src/main/java/org/apache/geronimo/ src/main/java/org/apache/geronimo/blueprint/ s...
Date Wed, 25 Nov 2009 06:28:21 GMT
Author: rwonly
Date: Wed Nov 25 06:28:19 2009
New Revision: 883991

URL: http://svn.apache.org/viewvc?rev=883991&view=rev
Log:
Commit the implementation of the blueprint MBeans, thanks Siqi for the help!

Added:
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/Activator.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintState.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPTarget.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/OSGiBlueprintEvent.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/TransferObject.java   (with props)
    geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/Util.java   (with props)

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml Wed Nov 25 06:28:19 2009
@@ -0,0 +1,28 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.apache.geronimo.blueprint</groupId>
+  <artifactId>org.apache.geronimo.blueprint.jmx.impl</artifactId>
+  <packaging>jar</packaging>
+  <version>1.0-SNAPSHOT</version>
+  
+  <name>org.apache.geronimo.blueprint.jmx.impl</name>
+  
+  <dependencies>
+	<dependency>
+		<groupId>org.osgi</groupId>
+		<artifactId>org.osgi.core</artifactId>
+		<version>4.2.0</version>
+	</dependency>
+	<dependency>
+		<groupId>org.osgi</groupId>
+		<artifactId>org.osgi.compendium</artifactId>
+		<version>4.2.0</version>
+	</dependency>
+	<dependency>
+		<groupId>org.apache.geronimo.blueprint</groupId>
+		<artifactId>org.apache.geronimo.blueprint.jmx</artifactId>
+		<version>1.0-SNAPSHOT</version>
+	</dependency>
+  </dependencies>
+</project>

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/pom.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/Activator.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/Activator.java?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/Activator.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/Activator.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,144 @@
+package org.apache.geronimo.blueprint.jmx.impl;
+
+import java.util.List;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.atomic.AtomicBoolean;
+
+import javax.management.InstanceAlreadyExistsException;
+import javax.management.InstanceNotFoundException;
+import javax.management.MBeanRegistrationException;
+import javax.management.MBeanServer;
+import javax.management.NotCompliantMBeanException;
+import javax.management.ObjectName;
+import javax.management.StandardMBean;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintStateMBean;
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.ServiceReference;
+import org.osgi.util.tracker.ServiceTracker;
+import org.osgi.util.tracker.ServiceTrackerCustomizer;
+
+public class Activator implements BundleActivator {
+    
+    protected BundleContext bundleContext;
+    
+    protected StandardMBean blueprintState;
+    protected ObjectName blueprintStateName;
+    
+    protected List<MBeanServer> mbeanServers = new CopyOnWriteArrayList<MBeanServer>();
+    protected ServiceTracker mbeanServiceTracker;
+    
+    protected AtomicBoolean servicesRegistered = new AtomicBoolean(false);
+    
+    public void start(BundleContext context) throws Exception {
+        this.bundleContext = context;
+        this.blueprintStateName = new ObjectName(BlueprintStateMBean.OBJECTNAME);
+        
+        //get mbeanServiceTracker
+        mbeanServiceTracker = new ServiceTracker(bundleContext, MBeanServer.class.getCanonicalName(), new MBeanServiceTracker());
+        //log.fine("Awaiting MBeanServer service registration");
+        mbeanServiceTracker.open();
+    }
+
+    public void stop(BundleContext context) throws Exception {
+        mbeanServiceTracker.close();
+        for (MBeanServer mbeanServer : mbeanServers) {
+            deregisterServices(mbeanServer);
+        }
+        mbeanServers.clear();        
+    }
+
+    class MBeanServiceTracker implements ServiceTrackerCustomizer {
+
+        public Object addingService(ServiceReference servicereference) {
+            try {
+                //log.fine("Adding MBeanServer: " + servicereference);
+                final MBeanServer mbeanServer = (MBeanServer) bundleContext.getService(servicereference);
+                mbeanServers.add(mbeanServer);
+                Runnable registration = new Runnable() {
+                    public void run() {
+                        Activator.this.registerServices(mbeanServer);
+                    }
+                };
+                Thread registrationThread = new Thread(registration, "JMX Core MBean Registration");
+                registrationThread.setDaemon(true);
+                registrationThread.start();
+
+                return mbeanServer;
+            } catch (RuntimeException e) {
+                //log.log(Level.SEVERE, "uncaught exception in addingService", e);
+                throw e;
+            }
+        }
+
+        public void modifiedService(ServiceReference servicereference,
+                Object obj) {
+            // no op
+        }
+
+        public void removedService(ServiceReference servicereference, Object obj) {
+            try {
+                //log.fine("Removing MBeanServer: " + servicereference);
+                final MBeanServer mbeanServer = (MBeanServer) bundleContext
+                        .getService(servicereference);
+                mbeanServers.remove(mbeanServer);
+                Runnable deregister = new Runnable() {
+                    public void run() {
+                        Activator.this.deregisterServices(mbeanServer);
+                    }
+                };
+
+                Thread deregisterThread = new Thread(deregister,
+                        "JMX Core MBean Deregistration");
+                deregisterThread.setDaemon(true);
+                deregisterThread.start();
+
+            } catch (Throwable e) {
+                //log.log(Level.FINE, "uncaught exception in removedService", e);
+            }
+        }
+    }
+    
+    protected synchronized void registerServices(MBeanServer mbeanServer) {
+        // create MBean
+        try {
+            blueprintState = new StandardMBean(new BlueprintState(bundleContext), BlueprintStateMBean.class);
+        } catch (NotCompliantMBeanException e) {
+            //log.log(Level.SEVERE, "Unable to create StandardMBean for BundleState", e);
+            return;
+        }
+        // register MBean to MBean server
+        //log.fine("Registering bundle state monitor with MBeanServer: " + mbeanServer + " with name: " + bundlesStateName);
+        try {
+            mbeanServer.registerMBean(blueprintState, blueprintStateName);
+        } catch (InstanceAlreadyExistsException e) {
+            //log.log(Level.FINE, "Cannot register OSGi BundleStateMBean", e);
+        } catch (MBeanRegistrationException e) {
+            //log.log(Level.SEVERE, "Cannot register OSGi BundleStateMBean", e);
+        } catch (NotCompliantMBeanException e) {
+            //log.log(Level.SEVERE, "Cannot register OSGi BundleStateMBean", e);
+        }
+        
+        servicesRegistered.set(true);
+    }
+    
+    protected synchronized void deregisterServices(MBeanServer mbeanServer) {
+        if (!servicesRegistered.get()) {
+            return;
+        }
+        // unregister MBean to MBean server
+        try {
+            mbeanServer.unregisterMBean(blueprintStateName);
+        } catch (InstanceNotFoundException e) {
+            //log.log(Level.FINEST, "OSGi BundleStateMBean not found on deregistration", e);
+        } catch (MBeanRegistrationException e) {
+            //log.log(Level.FINE, "OSGi BundleStateMBean deregistration problem", e);
+        }
+        // 
+        blueprintState = null;
+       
+        servicesRegistered.set(false);
+    }
+    
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/Activator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,130 @@
+package org.apache.geronimo.blueprint.jmx.impl;
+
+import java.io.IOException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+import org.apache.geronimo.blueprint.jmx.impl.codec.BPMetadata;
+import org.apache.geronimo.blueprint.jmx.impl.codec.Util;
+import org.osgi.framework.Bundle;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.Constants;
+import org.osgi.framework.InvalidSyntaxException;
+import org.osgi.framework.ServiceReference;
+import org.osgi.service.blueprint.container.BlueprintContainer;
+import org.osgi.service.blueprint.reflect.BeanMetadata;
+import org.osgi.service.blueprint.reflect.ComponentMetadata;
+import org.osgi.service.blueprint.reflect.ServiceMetadata;
+import org.osgi.service.blueprint.reflect.ServiceReferenceMetadata;
+
+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);
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintState.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/BlueprintState.java?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintState.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintState.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,80 @@
+package org.apache.geronimo.blueprint.jmx.impl;
+
+import java.io.IOException;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.management.MBeanRegistration;
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.TabularData;
+import javax.management.openmbean.TabularDataSupport;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintStateMBean;
+import org.apache.geronimo.blueprint.jmx.impl.codec.OSGiBlueprintEvent;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.ServiceRegistration;
+import org.osgi.service.blueprint.container.BlueprintEvent;
+import org.osgi.service.blueprint.container.BlueprintListener;
+
+public class BlueprintState implements BlueprintStateMBean, MBeanRegistration {
+
+    private BundleContext context;
+    
+    private ServiceRegistration listenerReg;
+        
+    private Map<String, CompositeData> dataMap = new HashMap<String, CompositeData>();
+    
+    public BlueprintState(BundleContext context){
+        this.context = context;
+    }
+    
+    public synchronized long[] getBlueprintBundleIds() throws IOException {
+        String[] bundleIdKeys= dataMap.keySet().toArray(new String[0]);
+        long[] bundleIds = new long[bundleIdKeys.length];
+        for (int i=0;i<bundleIdKeys.length;i++){
+            bundleIds[i] = Long.parseLong(bundleIdKeys[i]);
+        }
+        return bundleIds;
+    }
+    
+    public synchronized CompositeData getLastEvent(long bundleId) throws IOException {
+        return dataMap.get(String.valueOf(bundleId));
+    }
+
+    public synchronized TabularData getLastEvents() throws IOException {
+        TabularDataSupport table = new TabularDataSupport(BlueprintStateMBean.OSGI_BLUEPRINT_EVENTS_TYPE);
+        table.putAll(dataMap);
+        return table;
+    }
+    
+    public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception {
+        // no op
+        return name;
+    }
+    
+    public void postRegister(Boolean registrationDone) {
+        BlueprintListener listener =  new BlueprintStateListener();
+        // reg listener
+        listenerReg = context.registerService(BlueprintListener.class.getName(), listener, null);
+    }
+
+    public void preDeregister() throws Exception {
+        // unreg Listener
+        listenerReg.unregister();
+    }
+
+    public void postDeregister() {
+        // no op
+    }
+    
+    private class BlueprintStateListener implements BlueprintListener{
+        public synchronized void blueprintEvent(BlueprintEvent event) {
+            CompositeData data = new OSGiBlueprintEvent(event).asCompositeData();    
+            dataMap.put(String.valueOf(event.getBundle().getBundleId()), data);
+        }
+        
+    }
+
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/BlueprintState.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,64 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanArgument.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,157 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+import org.osgi.service.blueprint.reflect.BeanArgument;
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,53 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+import org.osgi.service.blueprint.reflect.BeanProperty;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPBeanProperty.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,78 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPCollectionMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,56 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPComponentMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,40 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPIdRefMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,54 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapEntry.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,79 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMapMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,5 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+public interface BPMetadata {
+	// marker interface
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,5 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+public interface BPNonNullMetadata extends BPMetadata{
+  //marker interface
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNonNullMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,12 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import javax.management.openmbean.CompositeData;
+
+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;}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPNullMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,57 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPPropsMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,40 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRefMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,48 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,68 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceListener.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,48 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPReferenceMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,70 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPRegistrationListener.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,135 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+import org.osgi.service.blueprint.reflect.MapEntry;
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,93 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintMetadataMBean;
+import org.osgi.service.blueprint.reflect.ReferenceListener;
+import org.osgi.service.blueprint.reflect.ServiceReferenceMetadata;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPServiceReferenceMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPTarget.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/BPTarget.java?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPTarget.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPTarget.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,5 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+public interface BPTarget extends BPNonNullMetadata{
+	// marker interface
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPTarget.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: 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=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java (added)
+++ 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:28:19 2009
@@ -0,0 +1,50 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+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;
+	}
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/BPValueMetadata.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/OSGiBlueprintEvent.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/OSGiBlueprintEvent.java?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/OSGiBlueprintEvent.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/OSGiBlueprintEvent.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,177 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.management.openmbean.CompositeData;
+import javax.management.openmbean.CompositeDataSupport;
+import javax.management.openmbean.OpenDataException;
+
+import org.apache.geronimo.blueprint.jmx.BlueprintStateMBean;
+import org.osgi.service.blueprint.container.BlueprintEvent;
+
+/**
+ * <p>
+ * This class represents the CODEC for the composite data representing a OSGi
+ * <link>BlueprintEvent</link>
+ * <p>
+ * It serves as both the documentation of the type structure and as the
+ * codification of the mechanism to convert to/from the CompositeData.
+ * <p>
+ * The structure of the composite data is:
+ * <table border="1">
+ * <tr>
+ * <td>bundleId</td>
+ * <td>long</td>
+ * </tr>
+ * <tr>
+ * <td>extenderBundleId</td>
+ * <td>long</td>
+ * </tr>
+ * <tr>
+ * <td>eventType</td>
+ * <td>int</td>
+ * </tr>
+ * <tr>
+ * <td>replay</td>
+ * <td>boolean</td>
+ * </tr>
+ * <tr>
+ * <td>timestamp</td>
+ * <td>long</td>
+ * </tr>
+ * <tr>
+ * <td>dependencies</td>
+ * <td>String[]</td>
+ * </tr>
+ * <tr>
+ * <td>exceptionMessage</td>
+ * <td>String</td>
+ * </tr>
+ * </table>
+ */
+
+public class OSGiBlueprintEvent {
+    
+    private long bundleId;
+
+    private long extenderBundleId;
+    
+    private int eventType;
+    
+    private boolean replay;
+    
+    private long timestamp;
+    
+    private String[] dependencies;
+
+    private String exceptionMessage;
+    
+
+    /**
+     * Construct an OSGiBlueprintEvent from the supplied <link>BlueprintEvent</link>
+     * 
+     * @param event
+     *            - the event to represent
+     */
+    public OSGiBlueprintEvent(BlueprintEvent event) {
+        this(event.getBundle().getBundleId(),
+                event.getExtenderBundle().getBundleId(),
+                event.getType(),
+                event.isReplay(),
+                event.getTimestamp(),
+                event.getDependencies(),
+                event.getCause().getMessage());
+    }
+
+    /**
+     * Construct an OSGiBlueprintEvent from the CompositeData representing the
+     * event
+     * 
+     * @param data
+     *            - the CompositeData representing the event.
+     */
+    @SuppressWarnings("boxing")
+    public OSGiBlueprintEvent(CompositeData data) {
+        this((Long) data.get(BlueprintStateMBean.BUNDLE_ID),
+                (Long) data.get(BlueprintStateMBean.EXTENDER_BUNDLE_ID),
+                (Integer) data.get(BlueprintStateMBean.EVENT_TYPE),
+                (Boolean) data.get(BlueprintStateMBean.REPLAY),
+                (Long) data.get(BlueprintStateMBean.TIMESTAMP),
+                (String[]) data.get(BlueprintStateMBean.DEPENDENCIES),
+                (String) data.get(BlueprintStateMBean.EXCEPTION_MESSAGE));
+    }
+
+    /**
+     * Construct the OSGiBlueprintEvent
+     * 
+     * @param bundleId
+     * @param extenderBundleId
+     * @param eventType
+     * @param replay
+     * @param timestamp
+     * @param dependencies
+     * @param exceptionMessage
+     */
+    public OSGiBlueprintEvent(long bundleId, long extenderBundleId, int eventType, boolean replay, long timestamp, String[] dependencies, String exceptionMessage){
+        this.bundleId = bundleId;
+        this.extenderBundleId = extenderBundleId;
+        this.eventType = eventType;
+        this.replay = replay;
+        this.timestamp = timestamp;
+        this.dependencies = dependencies;
+        this.exceptionMessage = exceptionMessage;
+    }
+    
+    /**
+     * Answer the receiver encoded as CompositeData
+     * 
+     * @return the CompositeData encoding of the receiver.
+     */
+    @SuppressWarnings("boxing")
+    public CompositeData asCompositeData() {
+        Map<String, Object> items = new HashMap<String, Object>();
+        items.put(BlueprintStateMBean.BUNDLE_ID, bundleId);
+        items.put(BlueprintStateMBean.EXTENDER_BUNDLE_ID, extenderBundleId);
+        items.put(BlueprintStateMBean.EVENT_TYPE, eventType);
+        items.put(BlueprintStateMBean.REPLAY, replay);
+        items.put(BlueprintStateMBean.TIMESTAMP, timestamp);
+        items.put(BlueprintStateMBean.DEPENDENCIES, dependencies);
+        items.put(BlueprintStateMBean.EXCEPTION_MESSAGE, exceptionMessage);
+        try {
+            return new CompositeDataSupport(BlueprintStateMBean.OSGI_BLUEPRINT_EVENT_TYPE, items);
+        } catch (OpenDataException e) {
+            throw new IllegalStateException("Cannot form blueprint event open data", e);
+        }
+    }
+    
+    public long getBundleId() {
+        return bundleId;
+    }
+
+    public long getExtenderBundleId() {
+        return extenderBundleId;
+    }
+
+    public int getEventType() {
+        return eventType;
+    }
+
+    public boolean isReplay() {
+        return replay;
+    }
+
+    public long getTimestamp() {
+        return timestamp;
+    }
+
+    public String[] getDependencies() {
+        return dependencies;
+    }
+
+    public String getExceptionMessage() {
+        return exceptionMessage;
+    }
+
+
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/OSGiBlueprintEvent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/TransferObject.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/TransferObject.java?rev=883991&view=auto
==============================================================================
--- geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/TransferObject.java (added)
+++ geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/TransferObject.java Wed Nov 25 06:28:19 2009
@@ -0,0 +1,7 @@
+package org.apache.geronimo.blueprint.jmx.impl.codec;
+
+import javax.management.openmbean.CompositeData;
+
+public interface TransferObject {
+	CompositeData asCompositeData();
+}

Propchange: geronimo/sandbox/rex/org.apache.geronimo.blueprint.jmx.impl/src/main/java/org/apache/geronimo/blueprint/jmx/impl/codec/TransferObject.java
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message