10 [SecurityPermission(
SecurityAction.InheritanceDemand, ControlEvidence =
true, ControlPolicy =
true)]
13 internal long m_userQuota;
15 internal long m_machineQuota;
17 internal long m_expirationDays;
19 internal bool m_permanentData;
23 private const string _strUserQuota =
"UserQuota";
25 private const string _strMachineQuota =
"MachineQuota";
27 private const string _strExpiry =
"Expiry";
29 private const string _strPermDat =
"Permanent";
67 m_userQuota =
long.MaxValue;
68 m_machineQuota =
long.MaxValue;
69 m_expirationDays =
long.MaxValue;
70 m_permanentData =
true;
76 m_expirationDays = 0
L;
77 m_permanentData =
false;
89 m_expirationDays = ExpirationDays;
90 m_permanentData = PermanentData;
98 m_expirationDays = ExpirationDays;
99 m_permanentData = PermanentData;
111 internal static long min(
long x,
long y)
120 internal static long max(
long x,
long y)
133 return ToXml(GetType().FullName);
146 if (m_machineQuota > 0)
150 if (m_expirationDays > 0)
156 securityElement.
AddAttribute(
"Permanent", m_permanentData.ToString());
163 return securityElement;
174 if (XMLUtil.IsUnrestricted(esd))
180 string text = esd.Attribute(
"Allowed");
188 m_userQuota =
long.MaxValue;
189 m_machineQuota =
long.MaxValue;
190 m_expirationDays =
long.MaxValue;
191 m_permanentData =
true;
194 string text2 = esd.Attribute(
"UserQuota");
196 text2 = esd.Attribute(
"MachineQuota");
198 text2 = esd.Attribute(
"Expiry");
200 text2 = esd.Attribute(
"Permanent");
201 m_permanentData = (text2 !=
null &&
bool.Parse(text2));
static string GetName(Type enumType, object value)
Retrieves the name of the constant in the specified enumeration that has the specified value.
static CultureInfo InvariantCulture
Gets the T:System.Globalization.CultureInfo object that is culture-independent (invariant).
override SecurityElement ToXml()
Creates an XML encoding of the permission and its current state.
Allows a permission to expose an unrestricted state.
bool IsUnrestricted()
Returns a value indicating whether the current permission is unrestricted.
override void FromXml(SecurityElement esd)
Reconstructs a permission with a specified state from an XML encoding.
static object Parse(Type enumType, string value)
Converts the string representation of the name or numeric value of one or more enumerated constants t...
IsolatedStorageContainment
Specifies the permitted use of isolated storage.
SecurityAction
Specifies the security actions that can be performed using declarative security.
Provides information about, and means to manipulate, the current environment and platform....
Provides the base class for enumerations.
IsolatedStorageContainment UsageAllowed
Gets or sets the type of isolated storage containment allowed.
Represents the XML object model for encoding security objects. This class cannot be inherited.
IsolatedStoragePermission(PermissionState state)
Initializes a new instance of the T:System.Security.Permissions.IsolatedStoragePermission class with ...
Defines the underlying structure of all code access permissions.
long UserQuota
Gets or sets the quota on the overall size of each user's total store.
The exception that is thrown when one of the arguments provided to a method is not valid.
PermissionState
Specifies whether a permission should have all or no access to resources at creation.
void AddAttribute(string name, string value)
Adds a name/value attribute to an XML element.
Specifies that the class can be serialized.
Represents access to generic isolated storage capabilities.
Provides information about a specific culture (called a locale for unmanaged code development)....