singrdk/base/Libraries/Policy/Area.cs

35 lines
1.1 KiB
C#
Raw Permalink Normal View History

2008-11-17 18:29:00 -05:00
// ----------------------------------------------------------------------------
2008-03-05 09:52:00 -05:00
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
2008-11-17 18:29:00 -05:00
// ----------------------------------------------------------------------------
2008-03-05 09:52:00 -05:00
using System.Collections;
2008-11-17 18:29:00 -05:00
namespace Microsoft.Singularity.Policy.Engine
{
2008-03-05 09:52:00 -05:00
// An Area is a contiguous region of objects, indexed by uints.
// The contents of an Area are held in a Hashtable.
// An optimization would use an object[] array.
internal class Area {
Hashtable _contents;
string _name;
internal readonly uint _order;
internal object this[
uint i
] { get { return _contents[i]; } set { _contents[i] = value; } }
internal Area(string name, uint order) {
_contents = new Hashtable();
_name = name;
_order = order;
}
internal Area(string name, Area area) {
_contents = area._contents;
_name = name;
_order = area._order;
}
public override string ToString() { return _name; }
}
}