Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.gemini.blueprint.mock
Class MockServiceRegistration

    java.lang.Object
      org.eclipse.gemini.blueprint.mock.MockServiceRegistration

All Implemented Interfaces:
  org.osgi.framework.ServiceRegistration

    public class MockServiceRegistration

extends Object
implements org.osgi.framework.ServiceRegistration

ServiceRegistration mock.

The mock allows the service properties modification (through `setProperties(Dictionary)`) as long as the underlying reference is of type `MockServiceReference`.

Author:
  Costin Leau

Constructor Summary
`MockServiceRegistration()` Constructs a new `MockServiceRegistration` instance using defaults.
`MockServiceRegistration(Dictionary props)` Constructs a new `MockServiceRegistration` instance with the given properties.
`MockServiceRegistration(String[] clazz, Dictionary props)` Constructs a new `MockServiceRegistration` instance using the given class names and properties.

Method Summary
`boolean` | `equals(Object obj)`
`org.osgi.framework.ServiceReference` | `getReference()`
`int` | `hashCode()`
`void` | `setProperties(Dictionary props)`
`void` | `setReference(org.osgi.framework.ServiceReference reference)` Sets the service reference associated with this registration.
`void` | `unregister()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### MockServiceRegistration

    public MockServiceRegistration()

  Constructs a new `MockServiceRegistration` instance using defaults.

### MockServiceRegistration

    public MockServiceRegistration(Dictionary props)

  Constructs a new `MockServiceRegistration` instance with the given properties.

  Parameters:
    `props` - registration properties

### MockServiceRegistration

    public MockServiceRegistration(String[] clazz,
                                   Dictionary props)

  Constructs a new `MockServiceRegistration` instance using the given class names and properties.

  Parameters:
    `clazz` -
    `props` -

Method Detail

### getReference

    public org.osgi.framework.ServiceReference getReference()

  Specified by:
    `getReference` in interface `org.osgi.framework.ServiceRegistration`

### setReference

    public void setReference(org.osgi.framework.ServiceReference reference)

  Sets the service reference associated with this registration.

  Parameters:
    `reference` - service reference

### setProperties

    public void setProperties(Dictionary props)

  Specified by:
    `setProperties` in interface `org.osgi.framework.ServiceRegistration`

### unregister

    public void unregister()

  Specified by:
    `unregister` in interface `org.osgi.framework.ServiceRegistration`

### equals

    public boolean equals(Object obj)

  Overrides:
    `equals` in class `Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2012. All Rights Reserved.