1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91
|
//------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
//------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.Text;
using System.Xml;
namespace System.ServiceModel.Security
{
public abstract class TrustVersion
{
readonly XmlDictionaryString trustNamespace;
readonly XmlDictionaryString prefix;
internal TrustVersion(XmlDictionaryString ns, XmlDictionaryString prefix)
{
this.trustNamespace = ns;
this.prefix = prefix;
}
public XmlDictionaryString Namespace
{
get
{
return this.trustNamespace;
}
}
public XmlDictionaryString Prefix
{
get
{
return this.prefix;
}
}
public static TrustVersion Default
{
get { return WSTrustFeb2005; }
}
public static TrustVersion WSTrustFeb2005
{
get { return WSTrustVersionFeb2005.Instance; }
}
public static TrustVersion WSTrust13
{
get { return WSTrustVersion13.Instance; }
}
class WSTrustVersionFeb2005 : TrustVersion
{
static readonly WSTrustVersionFeb2005 instance = new WSTrustVersionFeb2005();
protected WSTrustVersionFeb2005()
: base(XD.TrustFeb2005Dictionary.Namespace, XD.TrustFeb2005Dictionary.Prefix)
{
}
public static TrustVersion Instance
{
get
{
return instance;
}
}
}
class WSTrustVersion13 : TrustVersion
{
static readonly WSTrustVersion13 instance = new WSTrustVersion13();
protected WSTrustVersion13()
: base(DXD.TrustDec2005Dictionary.Namespace, DXD.TrustDec2005Dictionary.Prefix)
{
}
public static TrustVersion Instance
{
get
{
return instance;
}
}
}
}
}
|