170 lines
4.6 KiB
C#
170 lines
4.6 KiB
C#
// ========================================================================
|
|
// Copyright 2006 - Volian Enterprises, Inc. All rights reserved.
|
|
// Volian Enterprises - Proprietary Information - DO NOT COPY OR DISTRIBUTE
|
|
// ------------------------------------------------------------------------
|
|
// $Workfile: $ $Revision: $
|
|
// $Author: $ $Date: $
|
|
//
|
|
// $History: $
|
|
// ========================================================================
|
|
|
|
using System;
|
|
using System.Data;
|
|
using System.Data.SqlClient;
|
|
using Csla;
|
|
using Csla.Data;
|
|
using System.Configuration;
|
|
using System.IO;
|
|
|
|
namespace Volian.CSLA.Library
|
|
{
|
|
/// <summary>
|
|
/// ZStructInfo Generated by MyGeneration using the CSLA Object Mapping template
|
|
/// </summary>
|
|
[Serializable()]
|
|
public partial class ZStructInfo : ReadOnlyBase<ZStructInfo>
|
|
{
|
|
#region Business Methods
|
|
private int _StructureID;
|
|
[System.ComponentModel.DataObjectField(true, true)]
|
|
public int StructureID
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _StructureID;
|
|
}
|
|
}
|
|
private int _FromType;
|
|
public int FromType
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _FromType;
|
|
}
|
|
}
|
|
private int _FromID;
|
|
public int FromID
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _FromID;
|
|
}
|
|
}
|
|
private int _ContentType;
|
|
public int ContentType
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _ContentType;
|
|
}
|
|
}
|
|
private int _ContentID;
|
|
public int ContentID
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _ContentID;
|
|
}
|
|
}
|
|
private int _Level;
|
|
public int Level
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _Level;
|
|
}
|
|
}
|
|
private int _Item;
|
|
public int Item
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _Item;
|
|
}
|
|
}
|
|
private string _PPath = string.Empty;
|
|
public string PPath
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _PPath;
|
|
}
|
|
}
|
|
private string _Path = string.Empty;
|
|
public string Path
|
|
{
|
|
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
|
get
|
|
{
|
|
CanReadProperty(true);
|
|
return _Path;
|
|
}
|
|
}
|
|
// TODO: Replace base ZStructInfo.ToString function as necessary
|
|
/// <summary>
|
|
/// Overrides Base ToString
|
|
/// </summary>
|
|
/// <returns>A string representation of current ZStructInfo</returns>
|
|
//public override string ToString()
|
|
//{
|
|
// return base.ToString();
|
|
//}
|
|
// TODO: Check ZStructInfo.GetIdValue to assure that the ID returned is unique
|
|
/// <summary>
|
|
/// Overrides Base GetIdValue - Used internally by CSLA to determine equality
|
|
/// </summary>
|
|
/// <returns>A Unique ID for the current ZStructInfo</returns>
|
|
protected override object GetIdValue()
|
|
{
|
|
return _StructureID;
|
|
}
|
|
#endregion
|
|
#region Factory Methods
|
|
private ZStructInfo()
|
|
{ /* require use of factory methods */ }
|
|
public ZStruct Get()
|
|
{
|
|
return ZStruct.Get(_StructureID);
|
|
}
|
|
#endregion
|
|
#region Data Access Portal
|
|
internal ZStructInfo(SafeDataReader dr)
|
|
{
|
|
try
|
|
{
|
|
_StructureID = dr.GetInt32("StructureID");
|
|
_FromType = dr.GetInt32("FromType");
|
|
_FromID = dr.GetInt32("FromID");
|
|
_ContentType = dr.GetInt32("ContentType");
|
|
_ContentID = dr.GetInt32("ContentID");
|
|
_Level = dr.GetInt32("Level");
|
|
_Item = dr.GetInt32("Item");
|
|
_PPath = dr.GetString("PPath");
|
|
_Path = dr.GetString("Path");
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
Database.LogException("ZStructInfo.Constructor", ex);
|
|
throw new DbCslaException("ZStructInfo.Constructor", ex);
|
|
}
|
|
}
|
|
#endregion
|
|
} // Class
|
|
} // Namespace
|