singrdk/base/Libraries/Policy/ChoicePoint.cs

62 lines
1.8 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

2008-11-17 18:29:00 -05:00
namespace Microsoft.Singularity.Policy.Engine
{
2008-03-05 09:52:00 -05:00
// A ChoicePoint is a single Cell containing a choice point. This replaces
// the multiple cells used in the WAM in a more strongly typed way. The
// ChoicePoint is followed on the stack by copies of the arguments.
internal class ChoicePoint : Cell {
internal readonly uint _n;
internal readonly Address _ce;
internal readonly Address _cp;
internal readonly Address _b;
internal /* not readonly */ Address _bp;
internal readonly Address _tr;
internal readonly Address _h;
internal readonly Address _hb;
internal ChoicePoint(
uint n
, Address ce
, Address cp
, Address b
, Address bp
, Address tr
, Address h
, Address hb
) {
_n = n;
_ce = ce;
_cp = cp;
_b = b;
_bp = bp;
_tr = tr;
_h = h;
_hb = hb;
}
public override string ToString() {
return "<CHOICEPOINT "
+ _n.ToString()
+ " "
+ _ce.ToString()
+ " "
+ _cp.ToString()
+ " "
+ _b.ToString()
+ " "
+ _bp.ToString()
+ " "
+ _tr.ToString()
+ " "
+ _h.ToString()
+ " "
+ _hb.ToString()
+ ">";
}
}
}