967 lines
32 KiB
C#
967 lines
32 KiB
C#
using Sarand.Net.Standard.Base.Core;
|
|
using Sarand.Net.Standard.Base.Dbas;
|
|
using Sarand.Net.Standard.Base.Utils;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
|
|
//---------------------------------------------------------------------------
|
|
// Code generated by Sarand Database Utilities Mon 7-Mar-2022 10:06:56
|
|
//---------------------------------------------------------------------------
|
|
namespace Saxonite.Base.App
|
|
{
|
|
public class SaxDbDfn_Core
|
|
{
|
|
//-------------------------------------------------------------------
|
|
// Table identifiers.
|
|
public enum TableIdx
|
|
{
|
|
Unknown = 0,
|
|
ActivityIndex,
|
|
Article,
|
|
ItemAddress,
|
|
ItemImage,
|
|
ItemSport,
|
|
Organisation,
|
|
OrganisationEvent,
|
|
OrganisationOpportunity,
|
|
Region,
|
|
Sport,
|
|
UserAccount,
|
|
UserActivity,
|
|
UserOnline,
|
|
UserOrganisation,
|
|
UserRole,
|
|
UserSession,
|
|
UserSport,
|
|
UserSportExperience,
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Column identifiers.
|
|
public enum ColumnIdx
|
|
{
|
|
Unknown = 0,
|
|
ActivityIndex_ItemType,
|
|
ActivityIndex_ItemId,
|
|
ActivityIndex_SportId,
|
|
ActivityIndex_RegionId,
|
|
ActivityIndex_UserAccountIdOwner,
|
|
ActivityIndex_OrganisationIdOwner,
|
|
ActivityIndex_EffectiveOn,
|
|
ActivityIndex_ExpiresOn,
|
|
ActivityIndex_Notes,
|
|
ActivityIndex_Flags,
|
|
ActivityIndex_Status,
|
|
ActivityIndex_CreateOn,
|
|
ActivityIndex_CreateBy,
|
|
ActivityIndex_CreateHost,
|
|
ActivityIndex_UpdateOn,
|
|
ActivityIndex_UpdateBy,
|
|
ActivityIndex_UpdateHost,
|
|
Article_Id,
|
|
Article_UserAccountIdAuthor,
|
|
Article_OrganisationId,
|
|
Article_SportIdPrimary,
|
|
Article_RegionIdPrimary,
|
|
Article_Headline,
|
|
Article_Summary,
|
|
Article_BodyData,
|
|
Article_PublishedAt,
|
|
Article_Notes,
|
|
Article_Flags,
|
|
Article_Status,
|
|
Article_CreateOn,
|
|
Article_CreateBy,
|
|
Article_CreateHost,
|
|
Article_UpdateOn,
|
|
Article_UpdateBy,
|
|
Article_UpdateHost,
|
|
ItemAddress_Id,
|
|
ItemAddress_ItemType,
|
|
ItemAddress_ItemId,
|
|
ItemAddress_AddressType,
|
|
ItemAddress_Caption,
|
|
ItemAddress_Line1,
|
|
ItemAddress_Line2,
|
|
ItemAddress_Line3,
|
|
ItemAddress_Town,
|
|
ItemAddress_Province,
|
|
ItemAddress_RegionIdProvince,
|
|
ItemAddress_Country,
|
|
ItemAddress_RegionIdCountry,
|
|
ItemAddress_PostalCode,
|
|
ItemAddress_PhoneMain,
|
|
ItemAddress_LocationSource,
|
|
ItemAddress_LocationStoredAt,
|
|
ItemAddress_LocationUpdateRequired,
|
|
ItemAddress_LocationData,
|
|
ItemAddress_LocationFormattedAddress,
|
|
ItemAddress_LocationLatitude,
|
|
ItemAddress_LocationLongitude,
|
|
ItemAddress_LocationAltitude,
|
|
ItemAddress_Notes,
|
|
ItemAddress_Flags,
|
|
ItemAddress_Status,
|
|
ItemAddress_CreateOn,
|
|
ItemAddress_CreateBy,
|
|
ItemAddress_CreateHost,
|
|
ItemAddress_UpdateOn,
|
|
ItemAddress_UpdateBy,
|
|
ItemAddress_UpdateHost,
|
|
ItemImage_Id,
|
|
ItemImage_ItemType,
|
|
ItemImage_ItemId,
|
|
ItemImage_ImageType,
|
|
ItemImage_ImageSeq,
|
|
ItemImage_SessionUid,
|
|
ItemImage_ImageUid,
|
|
ItemImage_Filename,
|
|
ItemImage_Mime,
|
|
ItemImage_ContentType,
|
|
ItemImage_Width,
|
|
ItemImage_Height,
|
|
ItemImage_ImageData,
|
|
ItemImage_Notes,
|
|
ItemImage_Flags,
|
|
ItemImage_Status,
|
|
ItemImage_CreateOn,
|
|
ItemImage_CreateBy,
|
|
ItemImage_CreateHost,
|
|
ItemImage_UpdateOn,
|
|
ItemImage_UpdateBy,
|
|
ItemImage_UpdateHost,
|
|
ItemSport_Id,
|
|
ItemSport_ItemType,
|
|
ItemSport_ItemId,
|
|
ItemSport_SportId,
|
|
ItemSport_ItemSportData,
|
|
ItemSport_Notes,
|
|
ItemSport_Flags,
|
|
ItemSport_Status,
|
|
ItemSport_CreateOn,
|
|
ItemSport_CreateBy,
|
|
ItemSport_CreateHost,
|
|
ItemSport_UpdateOn,
|
|
ItemSport_UpdateBy,
|
|
ItemSport_UpdateHost,
|
|
Organisation_Id,
|
|
Organisation_Name,
|
|
Organisation_OrganisationType,
|
|
Organisation_OrganisationCategory,
|
|
Organisation_SportIdPrimary,
|
|
Organisation_RegionIdPrimary,
|
|
Organisation_CountryIso2Code,
|
|
Organisation_PhoneMain,
|
|
Organisation_PhoneAlt,
|
|
Organisation_Notes,
|
|
Organisation_Flags,
|
|
Organisation_Status,
|
|
Organisation_CreateOn,
|
|
Organisation_CreateBy,
|
|
Organisation_CreateHost,
|
|
Organisation_UpdateOn,
|
|
Organisation_UpdateBy,
|
|
Organisation_UpdateHost,
|
|
OrganisationEvent_Id,
|
|
OrganisationEvent_OrganisationId,
|
|
OrganisationEvent_SportIdPrimary,
|
|
OrganisationEvent_RegionIdCountry,
|
|
OrganisationEvent_EventAt,
|
|
OrganisationEvent_EventTypeCode,
|
|
OrganisationEvent_Summary,
|
|
OrganisationEvent_Details,
|
|
OrganisationEvent_EventData,
|
|
OrganisationEvent_PublishedAt,
|
|
OrganisationEvent_ExpiresAt,
|
|
OrganisationEvent_Notes,
|
|
OrganisationEvent_Flags,
|
|
OrganisationEvent_Status,
|
|
OrganisationEvent_CreateOn,
|
|
OrganisationEvent_CreateBy,
|
|
OrganisationEvent_CreateHost,
|
|
OrganisationEvent_UpdateOn,
|
|
OrganisationEvent_UpdateBy,
|
|
OrganisationEvent_UpdateHost,
|
|
OrganisationOpportunity_Id,
|
|
OrganisationOpportunity_OrganisationId,
|
|
OrganisationOpportunity_SportIdPrimary,
|
|
OrganisationOpportunity_RegionIdPrimary,
|
|
OrganisationOpportunity_OpportunityTypeCode,
|
|
OrganisationOpportunity_Position,
|
|
OrganisationOpportunity_Outline,
|
|
OrganisationOpportunity_OpportunityData,
|
|
OrganisationOpportunity_PublishedAt,
|
|
OrganisationOpportunity_ExpiresAt,
|
|
OrganisationOpportunity_Notes,
|
|
OrganisationOpportunity_Flags,
|
|
OrganisationOpportunity_Status,
|
|
OrganisationOpportunity_CreateOn,
|
|
OrganisationOpportunity_CreateBy,
|
|
OrganisationOpportunity_CreateHost,
|
|
OrganisationOpportunity_UpdateOn,
|
|
OrganisationOpportunity_UpdateBy,
|
|
OrganisationOpportunity_UpdateHost,
|
|
Region_Id,
|
|
Region_RegionType,
|
|
Region_CountryIso2Code,
|
|
Region_Name,
|
|
Region_Latitude,
|
|
Region_Longitude,
|
|
Region_RegionIdParent,
|
|
Region_Notes,
|
|
Region_Flags,
|
|
Region_Status,
|
|
Region_CreateOn,
|
|
Region_CreateBy,
|
|
Region_CreateHost,
|
|
Region_UpdateOn,
|
|
Region_UpdateBy,
|
|
Region_UpdateHost,
|
|
Sport_Id,
|
|
Sport_SportIdParent,
|
|
Sport_Name,
|
|
Sport_SpecialityLabel,
|
|
Sport_Notes,
|
|
Sport_Flags,
|
|
Sport_Status,
|
|
Sport_CreateOn,
|
|
Sport_CreateBy,
|
|
Sport_CreateHost,
|
|
Sport_UpdateOn,
|
|
Sport_UpdateBy,
|
|
Sport_UpdateHost,
|
|
UserAccount_Id,
|
|
UserAccount_EmailAddress,
|
|
UserAccount_Title,
|
|
UserAccount_FirstName,
|
|
UserAccount_Initials,
|
|
UserAccount_LastName,
|
|
UserAccount_About,
|
|
UserAccount_PhoneMain,
|
|
UserAccount_PhoneMobile,
|
|
UserAccount_PhoneAlt,
|
|
UserAccount_Gender,
|
|
UserAccount_DateOfBirthDay,
|
|
UserAccount_DateOfBirthMonth,
|
|
UserAccount_DateOfBirthYear,
|
|
UserAccount_RegionIdCountry,
|
|
UserAccount_RegionIdProvince,
|
|
UserAccount_JournalistData,
|
|
UserAccount_PasswordToken,
|
|
UserAccount_PasswordHashed,
|
|
UserAccount_PasswordHistory,
|
|
UserAccount_PasswordChangedAt,
|
|
UserAccount_LastLoginAt,
|
|
UserAccount_LastInvalidLoginAt,
|
|
UserAccount_InvalidLoginCount,
|
|
UserAccount_Notes,
|
|
UserAccount_Flags,
|
|
UserAccount_Status,
|
|
UserAccount_CreateOn,
|
|
UserAccount_CreateBy,
|
|
UserAccount_CreateHost,
|
|
UserAccount_UpdateOn,
|
|
UserAccount_UpdateBy,
|
|
UserAccount_UpdateHost,
|
|
UserActivity_Id,
|
|
UserActivity_UserAccountId,
|
|
UserActivity_ItemType,
|
|
UserActivity_ItemId,
|
|
UserActivity_CurrentlyListed,
|
|
UserActivity_ListedAtFirst,
|
|
UserActivity_ListedAtLast,
|
|
UserActivity_ViewedAtFirst,
|
|
UserActivity_ViewedAtLast,
|
|
UserActivity_Reaction,
|
|
UserActivity_ReactedAtFirst,
|
|
UserActivity_ReactedAtLast,
|
|
UserActivity_UserActivityData,
|
|
UserActivity_Notes,
|
|
UserActivity_Flags,
|
|
UserActivity_Status,
|
|
UserActivity_CreateOn,
|
|
UserActivity_CreateBy,
|
|
UserActivity_CreateHost,
|
|
UserActivity_UpdateOn,
|
|
UserActivity_UpdateBy,
|
|
UserActivity_UpdateHost,
|
|
UserOnline_UserAccountId,
|
|
UserOnline_OnlineAt,
|
|
UserOrganisation_Id,
|
|
UserOrganisation_UserAccountId,
|
|
UserOrganisation_OrganisationId,
|
|
UserOrganisation_OrganisationRoleCodes,
|
|
UserOrganisation_OrganisationRoleCount,
|
|
UserOrganisation_AdminComment,
|
|
UserOrganisation_Notes,
|
|
UserOrganisation_Flags,
|
|
UserOrganisation_Status,
|
|
UserOrganisation_CreateOn,
|
|
UserOrganisation_CreateBy,
|
|
UserOrganisation_CreateHost,
|
|
UserOrganisation_UpdateOn,
|
|
UserOrganisation_UpdateBy,
|
|
UserOrganisation_UpdateHost,
|
|
UserRole_Id,
|
|
UserRole_UserAccountId,
|
|
UserRole_UserRoleCode,
|
|
UserRole_LastLoginAt,
|
|
UserRole_LastInvalidLoginAt,
|
|
UserRole_InvalidLoginCount,
|
|
UserRole_Notes,
|
|
UserRole_Flags,
|
|
UserRole_Status,
|
|
UserRole_CreateOn,
|
|
UserRole_CreateBy,
|
|
UserRole_CreateHost,
|
|
UserRole_UpdateOn,
|
|
UserRole_UpdateBy,
|
|
UserRole_UpdateHost,
|
|
UserSession_UserAccountId,
|
|
UserSession_ActivityIndexIds,
|
|
UserSession_UserSessionData,
|
|
UserSession_Flags,
|
|
UserSession_CreateOn,
|
|
UserSession_UpdateOn,
|
|
UserSport_Id,
|
|
UserSport_UserAccountId,
|
|
UserSport_SportId,
|
|
UserSport_About,
|
|
UserSport_Participation,
|
|
UserSport_Officiating,
|
|
UserSport_UserSportData,
|
|
UserSport_Notes,
|
|
UserSport_Flags,
|
|
UserSport_Status,
|
|
UserSport_CreateOn,
|
|
UserSport_CreateBy,
|
|
UserSport_CreateHost,
|
|
UserSport_UpdateOn,
|
|
UserSport_UpdateBy,
|
|
UserSport_UpdateHost,
|
|
UserSportExperience_Id,
|
|
UserSportExperience_UserSportId,
|
|
UserSportExperience_PeriodFrom,
|
|
UserSportExperience_PeriodTo,
|
|
UserSportExperience_OrganisationId,
|
|
UserSportExperience_OrganisationName,
|
|
UserSportExperience_Summary,
|
|
UserSportExperience_Team,
|
|
UserSportExperience_League,
|
|
UserSportExperience_Speciality,
|
|
UserSportExperience_SpecialitiesOther,
|
|
UserSportExperience_RegionIdNation,
|
|
UserSportExperience_RegionIdProvince,
|
|
UserSportExperience_UserSportExperienceData,
|
|
UserSportExperience_Notes,
|
|
UserSportExperience_Flags,
|
|
UserSportExperience_Status,
|
|
UserSportExperience_CreateOn,
|
|
UserSportExperience_CreateBy,
|
|
UserSportExperience_CreateHost,
|
|
UserSportExperience_UpdateOn,
|
|
UserSportExperience_UpdateBy,
|
|
UserSportExperience_UpdateHost,
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Data members.
|
|
private static readonly int tableCount = 18;
|
|
private static readonly int columnCount = 321;
|
|
private static ulong maxTextLen = 0;
|
|
|
|
//-------------------------------------------------------------------
|
|
// Retrieve Table details (eg. name: 'Company').
|
|
public static int GetTableCount ()
|
|
{
|
|
return tableCount;
|
|
}
|
|
public static String GetTableName (TableIdx table, bool delimitReservedWords = true)
|
|
{
|
|
int tableIdx = (int)table - 1;
|
|
if (tableIdx < 0 || tableIdx >= tableCount) return String.Empty;
|
|
String tableName = tables[(int)tableIdx];
|
|
if (delimitReservedWords) tableName = DelimitReservedWord(tableName);
|
|
return tableName;
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Identify the table that corresponds with the specified column.
|
|
public static TableIdx GetTableForColumn (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return TableIdx.Unknown;
|
|
return columns[columnIdx].TableIdx;
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Retrieve the specified Column's name (Qualified include table name: '(<Table>.Column>)').
|
|
public static String GetColumnName (ColumnIdx column, bool delimitReservedWords = true)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return String.Empty;
|
|
String columnName = columns[columnIdx].Name;
|
|
if (delimitReservedWords) columnName = DelimitReservedWord(columnName);
|
|
return columnName;
|
|
}
|
|
public static String GetColumnNameQual (ColumnIdx column, String tableAlias = "", bool braces = false)
|
|
{
|
|
String columnName = GetColumnName(column);
|
|
if (!String.IsNullOrEmpty(columnName))
|
|
{
|
|
String tableName = StringUtil.EmptyOnNull(tableAlias);
|
|
if (tableName.IsEmpty()) tableName = GetTableName(GetTableForColumn(column));
|
|
columnName = tableName + (tableName.Length > 0 ? "." : "") + columnName;
|
|
if (braces)
|
|
columnName = "(" + columnName + ")";
|
|
}
|
|
return columnName;
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Reserved words.
|
|
private static DbReservedWordDelim reservedWordDelim = DbReservedWordDelim.SquareBrackets;
|
|
public static void SetReservedWordDelim (DbReservedWordDelim reservedWordDelim)
|
|
{
|
|
SaxDbDfn_Core.reservedWordDelim = reservedWordDelim;
|
|
}
|
|
public static bool IsReservedWord (String word)
|
|
{
|
|
if (String.IsNullOrEmpty(word)) return false;
|
|
if (reservedWords.Contains(word, StringComparer.OrdinalIgnoreCase)) return true;
|
|
return false;
|
|
}
|
|
public static String DelimitReservedWord (String word)
|
|
{
|
|
if (!IsReservedWord(word)) return word;
|
|
switch (reservedWordDelim)
|
|
{
|
|
case DbReservedWordDelim.None:
|
|
break;
|
|
case DbReservedWordDelim.DoubleQuotes:
|
|
word = "\"" + word + "\"";
|
|
break;
|
|
case DbReservedWordDelim.SquareBrackets:
|
|
default:
|
|
word = "[" + word + "]";
|
|
break;
|
|
}
|
|
return word;
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Retrieve information about the specified Column.
|
|
public static DbColumnDataType GetColDataType (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return DbColumnDataType.Unknown;
|
|
return columns[columnIdx].DataType;
|
|
}
|
|
public static short GetColNativeDataType (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return 0;
|
|
return columns[columnIdx].NativeDataType;
|
|
}
|
|
public static void SetMaxTextLen (ulong maxTextLen)
|
|
{
|
|
SaxDbDfn_Core.maxTextLen = maxTextLen;
|
|
}
|
|
public static bool IsColFmtText (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return false;
|
|
return (columns[columnIdx].DataType == DbColumnDataType.VarChar);
|
|
}
|
|
public static ulong GetColTextLen (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return 0;
|
|
if (columns[columnIdx].DataType == DbColumnDataType.VarChar)
|
|
{
|
|
ulong textLen = columns[columnIdx].DataLen;
|
|
if (maxTextLen > 0 && textLen > maxTextLen) textLen = maxTextLen;
|
|
return textLen;
|
|
}
|
|
return 0;
|
|
}
|
|
public static bool IsColFmtBool (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return false;
|
|
return (columns[columnIdx].DataType == DbColumnDataType.Bit);
|
|
}
|
|
public static bool IsColFmtNumeric (ColumnIdx column)
|
|
{
|
|
int columnIdx = (int)column - 1;
|
|
if (columnIdx < 0 || columnIdx >= columnCount) return false;
|
|
switch (columns[columnIdx].DataType)
|
|
{
|
|
case DbColumnDataType.TinyInt:
|
|
case DbColumnDataType.SmallInt:
|
|
case DbColumnDataType.Int:
|
|
case DbColumnDataType.BigInt:
|
|
case DbColumnDataType.Single:
|
|
case DbColumnDataType.Double:
|
|
case DbColumnDataType.Decimal:
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
// Table definitions.
|
|
private static readonly String[] tables =
|
|
{
|
|
"ActivityIndex",
|
|
"Article",
|
|
"ItemAddress",
|
|
"ItemImage",
|
|
"ItemSport",
|
|
"Organisation",
|
|
"OrganisationEvent",
|
|
"OrganisationOpportunity",
|
|
"Region",
|
|
"Sport",
|
|
"UserAccount",
|
|
"UserActivity",
|
|
"UserOnline",
|
|
"UserOrganisation",
|
|
"UserRole",
|
|
"UserSession",
|
|
"UserSport",
|
|
"UserSportExperience",
|
|
};
|
|
|
|
//-------------------------------------------------------------------
|
|
// Table column definitions.
|
|
private class ColumnDfn
|
|
{
|
|
internal TableIdx TableIdx { get; set; }
|
|
internal String Name { get; set; }
|
|
internal DbColumnDataType DataType { get; set; }
|
|
internal short NativeDataType { get; set; }
|
|
internal bool IsIdentity { get; set; }
|
|
internal ulong DataLen { get; set; }
|
|
internal ColumnDfn (int tableIdx, String name, int dataType, short nativeDataType, bool isIdentity, ulong dataLen)
|
|
{
|
|
this.TableIdx = (TableIdx)tableIdx;
|
|
this.Name = name;
|
|
this.DataType = (DbColumnDataType)dataType;
|
|
this.NativeDataType = nativeDataType;
|
|
this.IsIdentity = isIdentity;
|
|
this.DataLen = dataLen;
|
|
}
|
|
}
|
|
|
|
//-------------------------------------------------------------------
|
|
private static readonly ColumnDfn[] columns =
|
|
{
|
|
new ColumnDfn(1,"ItemType",3,5,false,5),
|
|
new ColumnDfn(1,"ItemId",5,-5,false,19),
|
|
new ColumnDfn(1,"SportId",4,4,false,10),
|
|
new ColumnDfn(1,"RegionId",4,4,false,10),
|
|
new ColumnDfn(1,"UserAccountIdOwner",4,4,false,10),
|
|
new ColumnDfn(1,"OrganisationIdOwner",4,4,false,10),
|
|
new ColumnDfn(1,"EffectiveOn",9,93,false,16),
|
|
new ColumnDfn(1,"ExpiresOn",9,93,false,16),
|
|
new ColumnDfn(1,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(1,"Flags",3,5,false,5),
|
|
new ColumnDfn(1,"Status",0,12,false,3),
|
|
new ColumnDfn(1,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(1,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(1,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(1,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(1,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(1,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(2,"Id",4,4,true,10),
|
|
new ColumnDfn(2,"UserAccountIdAuthor",4,4,false,10),
|
|
new ColumnDfn(2,"OrganisationId",4,4,false,10),
|
|
new ColumnDfn(2,"SportIdPrimary",4,4,false,10),
|
|
new ColumnDfn(2,"RegionIdPrimary",4,4,false,10),
|
|
new ColumnDfn(2,"Headline",0,-9,false,200),
|
|
new ColumnDfn(2,"Summary",0,-9,false,2000),
|
|
new ColumnDfn(2,"BodyData",0,-9,false,0),
|
|
new ColumnDfn(2,"PublishedAt",9,93,false,16),
|
|
new ColumnDfn(2,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(2,"Flags",3,5,false,5),
|
|
new ColumnDfn(2,"Status",0,12,false,3),
|
|
new ColumnDfn(2,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(2,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(2,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(2,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(2,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(2,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(3,"Id",5,-5,true,19),
|
|
new ColumnDfn(3,"ItemType",3,5,false,5),
|
|
new ColumnDfn(3,"ItemId",4,4,false,10),
|
|
new ColumnDfn(3,"AddressType",3,5,false,5),
|
|
new ColumnDfn(3,"Caption",0,-9,false,200),
|
|
new ColumnDfn(3,"Line1",0,-9,false,200),
|
|
new ColumnDfn(3,"Line2",0,-9,false,200),
|
|
new ColumnDfn(3,"Line3",0,-9,false,200),
|
|
new ColumnDfn(3,"Town",0,-9,false,100),
|
|
new ColumnDfn(3,"Province",0,-9,false,100),
|
|
new ColumnDfn(3,"RegionIdProvince",4,4,false,10),
|
|
new ColumnDfn(3,"Country",0,-9,false,100),
|
|
new ColumnDfn(3,"RegionIdCountry",4,4,false,10),
|
|
new ColumnDfn(3,"PostalCode",0,-9,false,32),
|
|
new ColumnDfn(3,"PhoneMain",0,-9,false,100),
|
|
new ColumnDfn(3,"LocationSource",0,12,false,100),
|
|
new ColumnDfn(3,"LocationStoredAt",9,93,false,16),
|
|
new ColumnDfn(3,"LocationUpdateRequired",1,-7,false,1),
|
|
new ColumnDfn(3,"LocationData",0,-9,false,4000),
|
|
new ColumnDfn(3,"LocationFormattedAddress",0,-9,false,4000),
|
|
new ColumnDfn(3,"LocationLatitude",8,3,false,9),
|
|
new ColumnDfn(3,"LocationLongitude",8,3,false,9),
|
|
new ColumnDfn(3,"LocationAltitude",8,3,false,9),
|
|
new ColumnDfn(3,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(3,"Flags",3,5,false,5),
|
|
new ColumnDfn(3,"Status",0,1,false,3),
|
|
new ColumnDfn(3,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(3,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(3,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(3,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(3,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(3,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(4,"Id",5,-5,true,19),
|
|
new ColumnDfn(4,"ItemType",3,5,false,5),
|
|
new ColumnDfn(4,"ItemId",4,4,false,10),
|
|
new ColumnDfn(4,"ImageType",3,5,false,5),
|
|
new ColumnDfn(4,"ImageSeq",2,-6,false,3),
|
|
new ColumnDfn(4,"SessionUid",5,-5,false,19),
|
|
new ColumnDfn(4,"ImageUid",4,4,false,10),
|
|
new ColumnDfn(4,"Filename",0,-9,false,1024),
|
|
new ColumnDfn(4,"Mime",0,12,false,64),
|
|
new ColumnDfn(4,"ContentType",0,12,false,128),
|
|
new ColumnDfn(4,"Width",4,4,false,10),
|
|
new ColumnDfn(4,"Height",4,4,false,10),
|
|
new ColumnDfn(4,"ImageData",10,-3,false,0),
|
|
new ColumnDfn(4,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(4,"Flags",3,5,false,5),
|
|
new ColumnDfn(4,"Status",0,12,false,3),
|
|
new ColumnDfn(4,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(4,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(4,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(4,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(4,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(4,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(5,"Id",4,4,true,10),
|
|
new ColumnDfn(5,"ItemType",3,5,false,5),
|
|
new ColumnDfn(5,"ItemId",4,4,false,10),
|
|
new ColumnDfn(5,"SportId",4,4,false,10),
|
|
new ColumnDfn(5,"ItemSportData",0,-9,false,0),
|
|
new ColumnDfn(5,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(5,"Flags",3,5,false,5),
|
|
new ColumnDfn(5,"Status",0,12,false,3),
|
|
new ColumnDfn(5,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(5,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(5,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(5,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(5,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(5,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(6,"Id",4,4,true,10),
|
|
new ColumnDfn(6,"Name",0,-9,false,100),
|
|
new ColumnDfn(6,"OrganisationType",0,12,false,3),
|
|
new ColumnDfn(6,"OrganisationCategory",0,12,false,3),
|
|
new ColumnDfn(6,"SportIdPrimary",4,4,false,10),
|
|
new ColumnDfn(6,"RegionIdPrimary",4,4,false,10),
|
|
new ColumnDfn(6,"CountryIso2Code",0,12,false,2),
|
|
new ColumnDfn(6,"PhoneMain",0,-9,false,50),
|
|
new ColumnDfn(6,"PhoneAlt",0,-9,false,50),
|
|
new ColumnDfn(6,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(6,"Flags",3,5,false,5),
|
|
new ColumnDfn(6,"Status",0,12,false,3),
|
|
new ColumnDfn(6,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(6,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(6,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(6,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(6,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(6,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(7,"Id",4,4,true,10),
|
|
new ColumnDfn(7,"OrganisationId",4,4,false,10),
|
|
new ColumnDfn(7,"SportIdPrimary",4,4,false,10),
|
|
new ColumnDfn(7,"RegionIdCountry",4,4,false,10),
|
|
new ColumnDfn(7,"EventAt",9,93,false,16),
|
|
new ColumnDfn(7,"EventTypeCode",0,12,false,3),
|
|
new ColumnDfn(7,"Summary",0,-9,false,200),
|
|
new ColumnDfn(7,"Details",0,-9,false,2000),
|
|
new ColumnDfn(7,"EventData",0,-9,false,0),
|
|
new ColumnDfn(7,"PublishedAt",9,93,false,16),
|
|
new ColumnDfn(7,"ExpiresAt",9,93,false,16),
|
|
new ColumnDfn(7,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(7,"Flags",3,5,false,5),
|
|
new ColumnDfn(7,"Status",0,12,false,3),
|
|
new ColumnDfn(7,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(7,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(7,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(7,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(7,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(7,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(8,"Id",4,4,true,10),
|
|
new ColumnDfn(8,"OrganisationId",4,4,false,10),
|
|
new ColumnDfn(8,"SportIdPrimary",4,4,false,10),
|
|
new ColumnDfn(8,"RegionIdPrimary",4,4,false,10),
|
|
new ColumnDfn(8,"OpportunityTypeCode",0,12,false,3),
|
|
new ColumnDfn(8,"Position",0,-9,false,200),
|
|
new ColumnDfn(8,"Outline",0,-9,false,2000),
|
|
new ColumnDfn(8,"OpportunityData",0,-9,false,0),
|
|
new ColumnDfn(8,"PublishedAt",9,93,false,16),
|
|
new ColumnDfn(8,"ExpiresAt",9,93,false,16),
|
|
new ColumnDfn(8,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(8,"Flags",3,5,false,5),
|
|
new ColumnDfn(8,"Status",0,12,false,3),
|
|
new ColumnDfn(8,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(8,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(8,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(8,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(8,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(8,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(9,"Id",4,4,true,10),
|
|
new ColumnDfn(9,"RegionType",3,5,false,5),
|
|
new ColumnDfn(9,"CountryIso2Code",0,12,false,2),
|
|
new ColumnDfn(9,"Name",0,-9,false,100),
|
|
new ColumnDfn(9,"Latitude",8,3,false,9),
|
|
new ColumnDfn(9,"Longitude",8,3,false,9),
|
|
new ColumnDfn(9,"RegionIdParent",4,4,false,10),
|
|
new ColumnDfn(9,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(9,"Flags",3,5,false,5),
|
|
new ColumnDfn(9,"Status",0,12,false,3),
|
|
new ColumnDfn(9,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(9,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(9,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(9,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(9,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(9,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(10,"Id",4,4,true,10),
|
|
new ColumnDfn(10,"SportIdParent",4,4,false,10),
|
|
new ColumnDfn(10,"Name",0,-9,false,100),
|
|
new ColumnDfn(10,"SpecialityLabel",3,5,false,5),
|
|
new ColumnDfn(10,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(10,"Flags",3,5,false,5),
|
|
new ColumnDfn(10,"Status",0,12,false,3),
|
|
new ColumnDfn(10,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(10,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(10,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(10,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(10,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(10,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(11,"Id",4,4,true,10),
|
|
new ColumnDfn(11,"EmailAddress",0,-9,false,200),
|
|
new ColumnDfn(11,"Title",0,-9,false,20),
|
|
new ColumnDfn(11,"FirstName",0,-9,false,100),
|
|
new ColumnDfn(11,"Initials",0,-9,false,10),
|
|
new ColumnDfn(11,"LastName",0,-9,false,100),
|
|
new ColumnDfn(11,"About",0,-9,false,2000),
|
|
new ColumnDfn(11,"PhoneMain",0,-9,false,50),
|
|
new ColumnDfn(11,"PhoneMobile",0,-9,false,50),
|
|
new ColumnDfn(11,"PhoneAlt",0,-9,false,50),
|
|
new ColumnDfn(11,"Gender",2,-6,false,3),
|
|
new ColumnDfn(11,"DateOfBirthDay",2,-6,false,3),
|
|
new ColumnDfn(11,"DateOfBirthMonth",2,-6,false,3),
|
|
new ColumnDfn(11,"DateOfBirthYear",3,5,false,5),
|
|
new ColumnDfn(11,"RegionIdCountry",4,4,false,10),
|
|
new ColumnDfn(11,"RegionIdProvince",4,4,false,10),
|
|
new ColumnDfn(11,"JournalistData",0,-9,false,0),
|
|
new ColumnDfn(11,"PasswordToken",0,12,false,32),
|
|
new ColumnDfn(11,"PasswordHashed",0,-9,false,100),
|
|
new ColumnDfn(11,"PasswordHistory",0,-9,false,0),
|
|
new ColumnDfn(11,"PasswordChangedAt",9,93,false,16),
|
|
new ColumnDfn(11,"LastLoginAt",9,93,false,16),
|
|
new ColumnDfn(11,"LastInvalidLoginAt",9,93,false,16),
|
|
new ColumnDfn(11,"InvalidLoginCount",3,5,false,5),
|
|
new ColumnDfn(11,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(11,"Flags",3,5,false,5),
|
|
new ColumnDfn(11,"Status",0,12,false,3),
|
|
new ColumnDfn(11,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(11,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(11,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(11,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(11,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(11,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(12,"Id",5,-5,true,19),
|
|
new ColumnDfn(12,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(12,"ItemType",3,5,false,5),
|
|
new ColumnDfn(12,"ItemId",5,-5,false,19),
|
|
new ColumnDfn(12,"CurrentlyListed",1,-7,false,1),
|
|
new ColumnDfn(12,"ListedAtFirst",9,93,false,16),
|
|
new ColumnDfn(12,"ListedAtLast",9,93,false,16),
|
|
new ColumnDfn(12,"ViewedAtFirst",9,93,false,16),
|
|
new ColumnDfn(12,"ViewedAtLast",9,93,false,16),
|
|
new ColumnDfn(12,"Reaction",3,5,false,5),
|
|
new ColumnDfn(12,"ReactedAtFirst",9,93,false,16),
|
|
new ColumnDfn(12,"ReactedAtLast",9,93,false,16),
|
|
new ColumnDfn(12,"UserActivityData",0,-9,false,0),
|
|
new ColumnDfn(12,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(12,"Flags",3,5,false,5),
|
|
new ColumnDfn(12,"Status",0,12,false,3),
|
|
new ColumnDfn(12,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(12,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(12,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(12,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(12,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(12,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(13,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(13,"OnlineAt",9,93,false,16),
|
|
new ColumnDfn(14,"Id",5,-5,true,19),
|
|
new ColumnDfn(14,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(14,"OrganisationId",4,4,false,10),
|
|
new ColumnDfn(14,"OrganisationRoleCodes",0,12,false,256),
|
|
new ColumnDfn(14,"OrganisationRoleCount",2,-6,false,3),
|
|
new ColumnDfn(14,"AdminComment",0,-9,false,2000),
|
|
new ColumnDfn(14,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(14,"Flags",3,5,false,5),
|
|
new ColumnDfn(14,"Status",0,12,false,3),
|
|
new ColumnDfn(14,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(14,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(14,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(14,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(14,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(14,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(15,"Id",5,-5,true,19),
|
|
new ColumnDfn(15,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(15,"UserRoleCode",0,12,false,16),
|
|
new ColumnDfn(15,"LastLoginAt",9,93,false,16),
|
|
new ColumnDfn(15,"LastInvalidLoginAt",9,93,false,16),
|
|
new ColumnDfn(15,"InvalidLoginCount",3,5,false,5),
|
|
new ColumnDfn(15,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(15,"Flags",3,5,false,5),
|
|
new ColumnDfn(15,"Status",0,12,false,3),
|
|
new ColumnDfn(15,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(15,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(15,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(15,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(15,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(15,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(16,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(16,"ActivityIndexIds",0,-9,false,0),
|
|
new ColumnDfn(16,"UserSessionData",0,-9,false,0),
|
|
new ColumnDfn(16,"Flags",3,5,false,5),
|
|
new ColumnDfn(16,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(16,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(17,"Id",5,-5,true,19),
|
|
new ColumnDfn(17,"UserAccountId",4,4,false,10),
|
|
new ColumnDfn(17,"SportId",4,4,false,10),
|
|
new ColumnDfn(17,"About",0,-9,false,2000),
|
|
new ColumnDfn(17,"Participation",3,5,false,5),
|
|
new ColumnDfn(17,"Officiating",3,5,false,5),
|
|
new ColumnDfn(17,"UserSportData",0,-9,false,0),
|
|
new ColumnDfn(17,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(17,"Flags",3,5,false,5),
|
|
new ColumnDfn(17,"Status",0,12,false,3),
|
|
new ColumnDfn(17,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(17,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(17,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(17,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(17,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(17,"UpdateHost",0,12,false,100),
|
|
new ColumnDfn(18,"Id",5,-5,true,19),
|
|
new ColumnDfn(18,"UserSportId",5,-5,false,19),
|
|
new ColumnDfn(18,"PeriodFrom",9,93,false,16),
|
|
new ColumnDfn(18,"PeriodTo",9,93,false,16),
|
|
new ColumnDfn(18,"OrganisationId",4,4,false,10),
|
|
new ColumnDfn(18,"OrganisationName",0,-9,false,200),
|
|
new ColumnDfn(18,"Summary",0,-9,false,2000),
|
|
new ColumnDfn(18,"Team",0,-9,false,64),
|
|
new ColumnDfn(18,"League",0,-9,false,64),
|
|
new ColumnDfn(18,"Speciality",0,-9,false,64),
|
|
new ColumnDfn(18,"SpecialitiesOther",0,-9,false,1000),
|
|
new ColumnDfn(18,"RegionIdNation",4,4,false,10),
|
|
new ColumnDfn(18,"RegionIdProvince",4,4,false,10),
|
|
new ColumnDfn(18,"UserSportExperienceData",0,-9,false,0),
|
|
new ColumnDfn(18,"Notes",0,-9,false,2000),
|
|
new ColumnDfn(18,"Flags",3,5,false,5),
|
|
new ColumnDfn(18,"Status",0,12,false,3),
|
|
new ColumnDfn(18,"CreateOn",9,93,false,23),
|
|
new ColumnDfn(18,"CreateBy",4,4,false,10),
|
|
new ColumnDfn(18,"CreateHost",0,12,false,100),
|
|
new ColumnDfn(18,"UpdateOn",9,93,false,23),
|
|
new ColumnDfn(18,"UpdateBy",4,4,false,10),
|
|
new ColumnDfn(18,"UpdateHost",0,12,false,100),
|
|
};
|
|
|
|
//-------------------------------------------------------------------
|
|
// Reserved words.
|
|
private static readonly List<String> reservedWords = new List<String>()
|
|
{
|
|
"ADD",
|
|
"ALL",
|
|
"ALTER",
|
|
"AND",
|
|
"ANY",
|
|
"AS",
|
|
"ASC",
|
|
"AVG",
|
|
"BEGIN",
|
|
"BETWEEN",
|
|
"BY",
|
|
"CASE",
|
|
"CAST",
|
|
"COLUMN",
|
|
"COMMIT",
|
|
"CONSTRAINT",
|
|
"CONVERT",
|
|
"COUNT",
|
|
"CREATE",
|
|
"CURRENCY",
|
|
"DEFAULT",
|
|
"DELETE",
|
|
"DESC",
|
|
"DISTINCT",
|
|
"DROP",
|
|
"ELSE",
|
|
"END",
|
|
"EXECUTE",
|
|
"EXISTS",
|
|
"FALSE",
|
|
"FROM",
|
|
"GRANT",
|
|
"GROUP",
|
|
"HAVING",
|
|
"IN",
|
|
"INDEX",
|
|
"INNER",
|
|
"INSERT",
|
|
"INTO",
|
|
"IS",
|
|
"JOIN",
|
|
"KEY",
|
|
"LEFT",
|
|
"LIKE",
|
|
"MAX",
|
|
"MIN",
|
|
"NOT",
|
|
"NULL",
|
|
"ON",
|
|
"OR",
|
|
"ORDER",
|
|
"OUTER",
|
|
"OUTPUT",
|
|
"PRIMARY",
|
|
"PROCEDURE",
|
|
"REVOKE",
|
|
"ROLLBACK",
|
|
"ROWCOUNT",
|
|
"SELECT",
|
|
"SET",
|
|
"SQL",
|
|
"SUM",
|
|
"TABLE",
|
|
"THEN",
|
|
"TRANSACTION",
|
|
"TRUE",
|
|
"UNION",
|
|
"UNIQUE",
|
|
"UPDATE",
|
|
"USER",
|
|
"VALUES",
|
|
"VIEW",
|
|
"WHEN",
|
|
"WHERE",
|
|
};
|
|
|
|
//-------------------------------------------------------------------
|
|
}
|
|
}
|