This commit is contained in:
Jsj
2008-05-16 18:07:47 +00:00
parent 9d0b3cd543
commit cda0291dbd
116 changed files with 4257 additions and 3382 deletions

View File

@@ -42,7 +42,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("FolderID",true);
CanReadProperty("FolderID", true);
if (_MyFolder != null) _FolderID = _MyFolder.FolderID;
return _FolderID;
}
@@ -54,7 +54,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("MyFolder",true);
CanReadProperty("MyFolder", true);
if (_MyFolder == null && _FolderID != 0) _MyFolder = Folder.Get(_FolderID);
return _MyFolder;
}
@@ -65,7 +65,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("ParentID",true);
CanReadProperty("ParentID", true);
if (_MyParent != null) _ParentID = _MyParent.FolderID;
return _ParentID;
}
@@ -76,14 +76,14 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("MyParent",true);
CanReadProperty("MyParent", true);
if (_MyParent == null && _ParentID != _FolderID) _MyParent = Folder.Get(_ParentID);
return _MyParent;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("MyParent",true);
CanWriteProperty("MyParent", true);
if (_MyParent != value)
{
_MyParent = value;
@@ -97,7 +97,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("DBID",true);
CanReadProperty("DBID", true);
if (_MyConnection != null) _DBID = _MyConnection.DBID;
return _DBID;
}
@@ -108,14 +108,14 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("MyConnection",true);
CanReadProperty("MyConnection", true);
if (_MyConnection == null && _DBID != 0) _MyConnection = Connection.Get(_DBID);
return _MyConnection;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("MyConnection",true);
CanWriteProperty("MyConnection", true);
if (_MyConnection != value)
{
_MyConnection = value;
@@ -129,13 +129,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Name",true);
CanReadProperty("Name", true);
return _Name;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("Name",true);
CanWriteProperty("Name", true);
if (value == null) value = string.Empty;
if (_Name != value)
{
@@ -150,13 +150,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Title",true);
CanReadProperty("Title", true);
return _Title;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("Title",true);
CanWriteProperty("Title", true);
if (value == null) value = string.Empty;
if (_Title != value)
{
@@ -171,13 +171,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("ShortName",true);
CanReadProperty("ShortName", true);
return _ShortName;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("ShortName",true);
CanWriteProperty("ShortName", true);
if (value == null) value = string.Empty;
if (_ShortName != value)
{
@@ -192,13 +192,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Config",true);
CanReadProperty("Config", true);
return _Config;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("Config",true);
CanWriteProperty("Config", true);
if (value == null) value = string.Empty;
if (_Config != value)
{
@@ -213,13 +213,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("DTS",true);
CanReadProperty("DTS", true);
return _DTS;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("DTS",true);
CanWriteProperty("DTS", true);
if (_DTS != value)
{
_DTS = value;
@@ -233,13 +233,13 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("UsrID",true);
CanReadProperty("UsrID", true);
return _UsrID;
}
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
set
{
CanWriteProperty("UsrID",true);
CanWriteProperty("UsrID", true);
if (value == null) value = string.Empty;
if (_UsrID != value)
{
@@ -255,7 +255,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_Name",true);
CanReadProperty("Connection_Name", true);
return _Connection_Name;
}
}
@@ -265,7 +265,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_Title",true);
CanReadProperty("Connection_Title", true);
return _Connection_Title;
}
}
@@ -275,7 +275,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_ConnectionString",true);
CanReadProperty("Connection_ConnectionString", true);
return _Connection_ConnectionString;
}
}
@@ -288,7 +288,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_ServerType",true);
CanReadProperty("Connection_ServerType", true);
return _Connection_ServerType;
}
}
@@ -298,7 +298,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_Config",true);
CanReadProperty("Connection_Config", true);
return _Connection_Config;
}
}
@@ -308,7 +308,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_DTS",true);
CanReadProperty("Connection_DTS", true);
return _Connection_DTS;
}
}
@@ -318,7 +318,7 @@ namespace VEPROMS.CSLA.Library
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
get
{
CanReadProperty("Connection_UsrID",true);
CanReadProperty("Connection_UsrID", true);
return _Connection_UsrID;
}
}
@@ -351,24 +351,24 @@ namespace VEPROMS.CSLA.Library
#endregion
#region ValidationRules
[NonSerialized]
private bool _CheckingBrokenRules=false;
private bool _CheckingBrokenRules = false;
public IVEHasBrokenRules HasBrokenRules
{
get
{
if(_CheckingBrokenRules)return null;
if (_CheckingBrokenRules) return null;
if (BrokenRulesCollection.Count > 0) return this;
try
{
_CheckingBrokenRules=true;
IVEHasBrokenRules hasBrokenRules = null;
if (_MyFolder != null && (hasBrokenRules = _MyFolder.HasBrokenRules) != null) return hasBrokenRules;
if (_MyConnection != null && (hasBrokenRules = _MyConnection.HasBrokenRules) != null) return hasBrokenRules;
return hasBrokenRules;
_CheckingBrokenRules = true;
IVEHasBrokenRules hasBrokenRules = null;
if (_MyFolder != null && (hasBrokenRules = _MyFolder.HasBrokenRules) != null) return hasBrokenRules;
if (_MyConnection != null && (hasBrokenRules = _MyConnection.HasBrokenRules) != null) return hasBrokenRules;
return hasBrokenRules;
}
finally
{
_CheckingBrokenRules=false;
_CheckingBrokenRules = false;
}
}
}
@@ -516,9 +516,9 @@ namespace VEPROMS.CSLA.Library
_DBID = _FormatFolderExtension.DefaultDBID;
_DTS = _FormatFolderExtension.DefaultDTS;
_UsrID = _FormatFolderExtension.DefaultUsrID;
_MyParent = myParent;
_Name = name;
_ShortName = shortName;
_MyParent = myParent;
_Name = name;
_ShortName = shortName;
ValidationRules.CheckRules();
}
internal FormatFolder(SafeDataReader dr)
@@ -530,7 +530,7 @@ namespace VEPROMS.CSLA.Library
#region Data Access Portal
private void Fetch(SafeDataReader dr)
{
if(_MyLog.IsDebugEnabled)_MyLog.DebugFormat("[{0}] FormatFolder.FetchDR", GetHashCode());
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] FormatFolder.FetchDR", GetHashCode());
try
{
_FolderID = dr.GetInt32("FolderID");
@@ -553,7 +553,7 @@ namespace VEPROMS.CSLA.Library
}
catch (Exception ex) // FKItem Fetch
{
if(_MyLog.IsErrorEnabled)_MyLog.Error("FormatFolder.FetchDR", ex);
if (_MyLog.IsErrorEnabled) _MyLog.Error("FormatFolder.FetchDR", ex);
throw new DbCslaException("FormatFolder.Fetch", ex);
}
MarkOld();