com.oracle.webservices.api.message
Interface PropertySet

All Known Subinterfaces:
DistributedPropertySet, MessageContext
All Known Implementing Classes:
AdditionalResponses, AddressingPropertySet, BaseDistributedPropertySet, BasePropertySet, DistributedPropertySet, InboundAccepted, InboundAcceptedImpl, OutboundDelivered, Packet, PropertySet, RequestContext, ServletConnectionImpl, ServletFakeArtifactSet, TCPClientTransport, TCPServiceChannelWSAdapter.ServiceChannelWSSatellite, ThrowableContainerPropertySet, TransactionPropertySet, WsaPropertyBag, WSDLDirectProperties, WSDLPortProperties, WSDLProperties, WSHTTPConnection, XMLPropertyBag

public interface PropertySet

A set of "properties" that can be accessed via strongly-typed fields as well as reflexibly through the property name.

Author:
Kohsuke Kawaguchi

Nested Class Summary
static interface PropertySet.Property
          Marks a field on PropertySet as a property of MessageContext.
 
Method Summary
 Map<String,Object> asMap()
          Creates a modifiable Map view of this PropertySet.
 boolean containsKey(Object key)
           
 Map<String,Object> createMapView()
          Deprecated. use newer implementation BasePropertySet.asMap() which produces readwrite Map
 Object get(Object key)
          Gets the name of the property.
 Object put(String key, Object value)
          Sets a property.
 Object remove(Object key)
           
 boolean supports(Object key)
          Checks if this PropertySet supports a property of the given name.
 

Method Detail

containsKey

boolean containsKey(Object key)

get

Object get(Object key)
Gets the name of the property.

Parameters:
key - This field is typed as Object to follow the Map.get(Object) convention, but if anything but String is passed, this method just returns null.

put

Object put(String key,
           Object value)
Sets a property.

Implementation Note

This method is slow. Code inside JAX-WS should define strongly-typed fields in this class and access them directly, instead of using this.

See Also:
PropertySet.Property

supports

boolean supports(Object key)
Checks if this PropertySet supports a property of the given name.


remove

Object remove(Object key)

createMapView

@Deprecated
Map<String,Object> createMapView()
Deprecated. use newer implementation BasePropertySet.asMap() which produces readwrite Map

Creates a Map view of this PropertySet.

This map is partially live, in the sense that values you set to it will be reflected to PropertySet.

However, this map may not pick up changes made to PropertySet after the view is created.

Returns:
always non-null valid instance.

asMap

Map<String,Object> asMap()
Creates a modifiable Map view of this PropertySet.

Changes done on this Map or on PropertySet object work in both directions - values made to Map are reflected to PropertySet and changes done using getters/setters on PropertySet object are automatically reflected in this Map.

If necessary, it also can hold other values (not present on PropertySet) - PropertySet#mapAllowsAdditionalProperties

Returns:
always non-null valid instance.


Copyright © 2005-2015 Oracle Corporation. All Rights Reserved.