System.Runtime.Remoting.Channels.BaseChannelObjectWithProperties Class

Assembly: Mscorlib.dll
Namespace: System.Runtime.Remoting.Channels
Summary
Provides a base implementation of a channel object that wants to provide a dictionary interface to its properties.
C# Syntax:
public abstract class BaseChannelObjectWithProperties : IDictionary, ICollection, IEnumerable
Remarks
BaseChannelObjectWithProperties is the base class for BaseChannelWithProperties and BaseChannelSinkWithProperties. BaseChannelWithProperties and BaseChannelSinkWithProperties can be used as the base classes for channels and channel sinks that want to provide named properties.

BaseChannelObjectWithProperties handles the complex task of asking a channel object for its properties.



Notes to inheritors: When you inherit from BaseChannelObjectWithProperties, you must override the BaseChannelObjectWithProperties.Keys property and the BaseChannelObjectWithProperties.Item property.
See also:
System.Runtime.Remoting.Channels Namespace

System.Runtime.Remoting.Channels.BaseChannelObjectWithProperties Member List:

Public Constructors
ctor #1 Default constructor. This constructor is called by derived class constructors to initialize state in this type.
Initializes a new instance of the BaseChannelObjectWithProperties class.
Public Properties
Count Read-only

Gets the number of properties associated with the current channel object.
IsFixedSize Read-only

Gets a Boolean value indicating whether the number of properties that can be entered into the current channel object is fixed.
IsReadOnly Read-only

Gets a Boolean value indicating whether the collection of properties in the current channel object is read-only.
IsSynchronized Read-only

Gets a value indicating whether the current dictionary of channel object properties is synchronized.
Item Read-write

Gets or sets the property associated with the specified key.
Keys Read-only

When implemented by a derived class, gets an ICollection of keys that the channel object properties are associated with.
Properties Read-only

Gets an IDictionary of the channel properties associated with the current channel object.
SyncRoot Read-only

Gets an object that is used to synchronize access to the BaseChannelObjectWithProperties.
Values Read-only

Gets an ICollection of the values of the properties associated with the current channel object.
Public Methods
Add The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
Clear The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
Contains Returns a Boolean value indicating whether the current channel object contains a property associated with the specified key.
CopyTo The current method is not supported by the BaseChannelObjectWithProperties.
Equals
(inherited from System.Object)
See base class member description: System.Object.Equals

Derived from System.Object, the primary base class for all objects.
GetEnumerator Returns an IDictionaryEnumerator that enumerates over all the properties associated with the current channel object.
GetHashCode
(inherited from System.Object)
See base class member description: System.Object.GetHashCode

Derived from System.Object, the primary base class for all objects.
GetType
(inherited from System.Object)
See base class member description: System.Object.GetType

Derived from System.Object, the primary base class for all objects.
Remove The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
ToString
(inherited from System.Object)
See base class member description: System.Object.ToString

Derived from System.Object, the primary base class for all objects.
Protected Methods
Finalize
(inherited from System.Object)
See base class member description: System.Object.Finalize

Derived from System.Object, the primary base class for all objects.
MemberwiseClone
(inherited from System.Object)
See base class member description: System.Object.MemberwiseClone

Derived from System.Object, the primary base class for all objects.

Hierarchy:


System.Runtime.Remoting.Channels.BaseChannelObjectWithProperties Member Details

ctor #1
Summary
Initializes a new instance of the BaseChannelObjectWithProperties class.

Default constructor. This constructor is called by derived class constructors to initialize state in this type.
C# Syntax:
public BaseChannelObjectWithProperties();

Return to top


Property: Count (read-only)
Summary
Gets the number of properties associated with the current channel object.
C# Syntax:
public virtual int Count {get;}
Implements:
ICollection.Count

Return to top


Property: IsFixedSize (read-only)
Summary
Gets a Boolean value indicating whether the number of properties that can be entered into the current channel object is fixed.
C# Syntax:
public virtual bool IsFixedSize {get;}
Implements:
IDictionary.IsFixedSize
Remarks
In the current implementation BaseChannelObjectWithProperties.IsFixedSize returns true.

Return to top


Property: IsReadOnly (read-only)
Summary
Gets a Boolean value indicating whether the collection of properties in the current channel object is read-only.
C# Syntax:
public virtual bool IsReadOnly {get;}
Implements:
IDictionary.IsReadOnly
Remarks
In the current implementation BaseChannelObjectWithProperties.IsReadOnly returns false.

Return to top


Property: IsSynchronized (read-only)
Summary
Gets a value indicating whether the current dictionary of channel object properties is synchronized.
C# Syntax:
public virtual bool IsSynchronized {get;}
Implements:
ICollection.IsSynchronized
Remarks
The current implementation of BaseChannelObjectWithProperties.IsSynchronized returns false.

Return to top


Property: Item (read-write)
Summary
Gets or sets the property associated with the specified key.
C# Syntax:
public virtual object this[object key] {get; set;}
Parameters:

key

The key the requested property is associated with.

Exceptions
Exception Type Condition
NotImplementedException The property is called.
Implements:
IDictionary.Item
Remarks


Notes to inheritors: It is necessary to implement the current property for the derived channel sink to function.

Return to top


Property: Keys (read-only)
Summary
When implemented by a derived class, gets an ICollection of keys that the channel object properties are associated with.
C# Syntax:
public virtual ICollection Keys {get;}
Implements:
IDictionary.Keys
Remarks


Notes to inheritors: It is necessary to implement the current property for the derived channel sink to function.

Return to top


Property: Properties (read-only)
Summary
Gets an IDictionary of the channel properties associated with the current channel object.
C# Syntax:
public virtual IDictionary Properties {get;}
Remarks
Channels properties are used to configure the channel at run time.

Return to top


Property: SyncRoot (read-only)
Summary
Gets an object that is used to synchronize access to the BaseChannelObjectWithProperties.
C# Syntax:
public virtual object SyncRoot {get;}
Implements:
ICollection.SyncRoot
Remarks
The current implementation of BaseChannelObjectWithProperties.SyncRoot returns a reference to the current instance of BaseChannelObjectWithProperties.

Return to top


Property: Values (read-only)
Summary
Gets an ICollection of the values of the properties associated with the current channel object.
C# Syntax:
public virtual ICollection Values {get;}
Implements:
IDictionary.Values

Return to top


Method: Add(
   object key,
   object value
)
Summary
The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
C# Syntax:
public virtual void Add(
   object key,
   object value
);
Parameters:

key

Indicates the key associated with the object contained in the value parameter.

value

Indicates the value to add.

Exceptions
Exception Type Condition
NotSupportedException The method was called.
Implements:
IDictionary.Add

Return to top


Method: Clear()
Summary
The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
C# Syntax:
public virtual void Clear();
Exceptions
Exception Type Condition
NotSupportedException The method was called.
Implements:
IDictionary.Clear

Return to top


Method: Contains(
   object key
)
Summary
Returns a Boolean value indicating whether the current channel object contains a property associated with the specified key.
C# Syntax:
public virtual bool Contains(
   object key
);
Parameters:

key

The key the requested property is associated with.

Return Value:
A Boolean value indicating whether the current channel object contains a property associated with the specified key.
Implements:
IDictionary.Contains
Remarks

Return to top


Method: CopyTo(
   Array array,
   int index
)
Summary
The current method is not supported by the BaseChannelObjectWithProperties.
C# Syntax:
public virtual void CopyTo(
   Array array,
   int index
);
Parameters:

array

The array to copy the properties to.

index

The index where to begin copying.

Exceptions
Exception Type Condition
NotSupportedException The method was called.
Implements:
ICollection.CopyTo

Return to top


Method: Equals(
   object obj
)
Inherited
See base class member description: System.Object.Equals
C# Syntax:
public virtual bool Equals(
   object obj
);

For more information on members inherited from System.Object click on the link above.

Return to top


Method: Finalize()
Inherited
See base class member description: System.Object.Finalize
C# Syntax:
~BaseChannelObjectWithProperties();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetEnumerator()
Summary
Returns an IDictionaryEnumerator that enumerates over all the properties associated with the current channel object.
C# Syntax:
public virtual IDictionaryEnumerator GetEnumerator();
Return Value:
An IDictionaryEnumerator that enumerates over all the properties associated with the current channel object.
Implements:
IDictionary.GetEnumerator

Return to top


Method: GetHashCode()
Inherited
See base class member description: System.Object.GetHashCode
C# Syntax:
public virtual int GetHashCode();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetType()
Inherited
See base class member description: System.Object.GetType
C# Syntax:
public Type GetType();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: MemberwiseClone()
Inherited
See base class member description: System.Object.MemberwiseClone
C# Syntax:
protected object MemberwiseClone();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: Remove(
   object key
)
Summary
The current method must not be implemented because it does not apply to the way IDictionary is being used in this case, and because BaseChannelObjectWithProperties.IsFixedSize returns true.
C# Syntax:
public virtual void Remove(
   object key
);
Parameters:

key

The key that the object being removed is associated with.

Exceptions
Exception Type Condition
NotSupportedException The method was called.
Implements:
IDictionary.Remove

Return to top


Method: ToString()
Inherited
See base class member description: System.Object.ToString
C# Syntax:
public virtual string ToString();

For more information on members inherited from System.Object click on the link above.

Return to top


Top of page

Copyright (c) 2002 Microsoft Corporation. All rights reserved.