本文整理汇总了C#中DS类的典型用法代码示例。如果您正苦于以下问题:C# DS类的具体用法?C# DS怎么用?C# DS使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
DS类属于命名空间,在下文中一共展示了DS类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: KinectFieldImageTextureFloat
public KinectFieldImageTextureFloat(DS.Simulation.CompositeFieldImage.KinectFieldImage source, Color3 color, KinectFieldImageType type)
{
m_Source = source;
m_Color = color;
m_ImageType = type;
m_Image = new ImageBoxFloat(null);
m_Image.OverlayType = RugTech1.Framework.Effects.ImposterOverlayType.Add;
}
开发者ID:RugCode,项目名称:drg-pt,代码行数:10,代码来源:KinectFieldImageTextureFloat.cs
示例2: Insert
//----------------------------------------------------------------
/// Insert record: Activity
//----------------------------------------------------------------
public override IDataReader Insert(DS ds )
{
_dbCommand = _db.GetStoredProcCommand( "InsertActivity");
_db.AddInParameter(_dbCommand, ds.Activity.Visit_IDColumn.ToString(), DbType.Int32,ds.Activity.Rows[0][ds.Activity.Visit_IDColumn.ToString()]);
_db.AddInParameter(_dbCommand, ds.Activity.Activity_SequenceColumn.ToString(), DbType.Int32,ds.Activity.Rows[0][ds.Activity.Activity_SequenceColumn.ToString()]);
_db.AddInParameter(_dbCommand, ds.Activity.Activity_Type_IDColumn.ToString(), DbType.Int32,ds.Activity.Rows[0][ds.Activity.Activity_Type_IDColumn.ToString()]);
_db.AddInParameter(_dbCommand, ds.Activity.TimeColumn.ToString(), DbType.DateTime,ds.Activity.Rows[0][ds.Activity.TimeColumn.ToString()]);
_db.AddInParameter(_dbCommand, ds.Activity.TextColumn.ToString(), DbType.String,ds.Activity.Rows[0][ds.Activity.TextColumn.ToString()]);
_db.AddInParameter(_dbCommand, ds.Activity.IDColumn.ToString(), DbType.Int32,ds.Activity.Rows[0][ds.Activity.IDColumn.ToString()]);
IDataReader dr = _db.ExecuteReader( _dbCommand,_transaction);
dr.Close();
return dr;
}
开发者ID:shhyder,项目名称:MapApplication,代码行数:16,代码来源:Activity.cs
示例3: MapLogType
List<Business.LogType> MapLogType(DS.LogTypeDataTable tb)
{
if (tb == null || tb.Rows.Count == 0)
{
return null;
}
List<Business.LogType> logTypeList = new List<Business.LogType>();
int count = tb.Rows.Count;
for (int i = 0; i < count; i++)
{
Business.LogType logType = new Business.LogType();
logType.ID = tb[i].LogTypeID;
logType.Name = tb[i].Name;
logTypeList.Add(logType);
}
return logTypeList;
}
开发者ID:ngthanhducit,项目名称:TradingServer1502,代码行数:17,代码来源:DBWLogType.cs
示例4: MapNews
private List<Business.News> MapNews(DS.NewsDataTable tbNews)
{
List<Business.News> result = new List<Business.News>();
if (tbNews != null)
{
int count = tbNews.Count;
for (int i = 0; i < count; i++)
{
Business.News newNews = new Business.News();
newNews.Body = tbNews[i].Body;
newNews.Catetory = tbNews[i].Category;
newNews.DateCreated = tbNews[i].DateCreated;
newNews.ID = tbNews[i].ID;
newNews.Title = tbNews[i].Title;
result.Add(newNews);
}
}
return result;
}
开发者ID:ngthanhducit,项目名称:TradingServer1502,代码行数:20,代码来源:DBWNews.cs
示例5: USlotSync
/*public USlotSync():base(DS.SyncType.HARD, DateTime.Now)
{
}
*/
public USlotSync(DS.SyncType syncType, DateTime dateTime, long logid)
{
// TODO: Complete member initialization
this.syncType = syncType;
this.syncTime = dateTime;
timer = new DispatcherTimer();
this.logid = logid;
InitializeComponent();
this.UTIME.Text = syncTime.ToLongDateString() + " " + syncTime.ToLongTimeString();
this.USYNCTEXT.Text = syncType.ToString();
timer.Interval = TimeSpan.FromSeconds(10);
evtTick = new EventHandler(timer_Tick);
timer.Tick += evtTick;
}
开发者ID:kaizadj,项目名称:ebu-radio-production,代码行数:25,代码来源:USlotSync.xaml.cs
示例6: Lex
[System.Security.SecuritySafeCritical] // auto-generated
private static Boolean Lex(DS dps, ref __DTString str, ref DateTimeToken dtok, ref DateTimeRawInfo raw, ref DateTimeResult result, ref DateTimeFormatInfo dtfi, DateTimeStyles styles)
{
TokenType tokenType;
int tokenValue;
int indexBeforeSeparator;
char charBeforeSeparator;
TokenType sep;
dtok.dtt = DTT.Unk; // Assume the token is unkown.
str.GetRegularToken(out tokenType, out tokenValue, dtfi);
#if _LOGGING
// Builds with _LOGGING defined (x86dbg, amd64chk, etc) support tracing
// Set the following internal-only/unsupported environment variables to enable DateTime tracing to the console:
//
// COMPlus_LogEnable=1
// COMPlus_LogToConsole=1
// COMPlus_LogLevel=9
// COMPlus_ManagedLogFacility=0x00001000
if (_tracingEnabled) {
BCLDebug.Trace("DATETIME", "[DATETIME] Lex({0})\tpos:{1}({2}), {3}, DS.{4}", Hex(str.Value),
str.Index, Hex(str.m_current), tokenType, dps);
}
#endif // _LOGGING
// Look at the regular token.
switch (tokenType) {
case TokenType.NumberToken:
case TokenType.YearNumberToken:
if (raw.numCount == 3 || tokenValue == -1) {
result.SetFailure(ParseFailureKind.Format, "Format_BadDateTime", null);
LexTraceExit("0010", dps);
return false;
}
//
// This is a digit.
//
// If the previous parsing state is DS.T_NNt (like 12:01), and we got another number,
// so we will have a terminal state DS.TX_NNN (like 12:01:02).
// If the previous parsing state is DS.T_Nt (like 12:), and we got another number,
// so we will have a terminal state DS.TX_NN (like 12:01).
//
// Look ahead to see if the following character is a decimal point or timezone offset.
// This enables us to parse time in the forms of:
// "11:22:33.1234" or "11:22:33-08".
if (dps == DS.T_NNt) {
if ((str.Index < str.len - 1)) {
char nextCh = str.Value[str.Index];
if (nextCh == '.') {
// While ParseFraction can fail, it just means that there were no digits after
// the dot. In this case ParseFraction just removes the dot. This is actually
// valid for cultures like Albanian, that join the time marker to the time with
// with a dot: e.g. "9:03.MD"
ParseFraction(ref str, out raw.fraction);
}
}
}
if (dps == DS.T_NNt || dps == DS.T_Nt) {
if ((str.Index < str.len - 1)) {
if (false == HandleTimeZone(ref str, ref result))
{
LexTraceExit("0020 (value like \"12:01\" or \"12:\" followed by a non-TZ number", dps);
return false;
}
}
}
dtok.num = tokenValue;
if (tokenType == TokenType.YearNumberToken)
{
if (raw.year == -1)
{
raw.year = tokenValue;
//
// If we have number which has 3 or more digits (like "001" or "0001"),
// we assume this number is a year. Save the currnet raw.numCount in
// raw.year.
//
switch (sep = str.GetSeparatorToken(dtfi, out indexBeforeSeparator, out charBeforeSeparator)) {
case TokenType.SEP_End:
dtok.dtt = DTT.YearEnd;
break;
case TokenType.SEP_Am:
case TokenType.SEP_Pm:
if (raw.timeMark == TM.NotSet) {
raw.timeMark = (sep == TokenType.SEP_Am ? TM.AM : TM.PM);
dtok.dtt = DTT.YearSpace;
} else {
result.SetFailure(ParseFailureKind.Format, "Format_BadDateTime", null);
LexTraceExit("0030 (TM.AM/TM.PM Happened more than 1x)", dps);
}
break;
case TokenType.SEP_Space:
dtok.dtt = DTT.YearSpace;
break;
case TokenType.SEP_Date:
dtok.dtt = DTT.YearDateSep;
//.........这里部分代码省略.........
开发者ID:ChuangYang,项目名称:coreclr,代码行数:101,代码来源:DateTimeParse.cs
示例7: PTSTraceExit
internal static void PTSTraceExit(DS dps, bool passed) {
#if _LOGGING
if (!_tracingEnabled)
return;
BCLDebug.Trace("DATETIME", "[DATETIME] ProcessTerminalState {0} @ DS.{1}", passed ? "passed" : "failed", dps);
#endif // _LOGGING
}
开发者ID:ChuangYang,项目名称:coreclr,代码行数:7,代码来源:DateTimeParse.cs
示例8: ProcessHebrewTerminalState
////////////////////////////////////////////////////////////////////////
//
// Actions:
// This is used by DateTime.Parse().
// Process the terminal state for the Hebrew calendar parsing.
//
////////////////////////////////////////////////////////////////////////
internal static Boolean ProcessHebrewTerminalState(DS dps, ref DateTimeResult result, ref DateTimeStyles styles, ref DateTimeRawInfo raw, DateTimeFormatInfo dtfi) {
// The following are accepted terminal state for Hebrew date.
switch (dps) {
case DS.DX_MNN:
// Deal with the default long/short date format when the year number is ambigous (i.e. year < 100).
raw.year = raw.GetNumber(1);
if (!dtfi.YearMonthAdjustment(ref raw.year, ref raw.month, true)) {
result.SetFailure(ParseFailureKind.FormatBadDateTimeCalendar, "Format_BadDateTimeCalendar", null);
return false;
}
if (!GetDayOfMNN(ref result, ref raw, dtfi)) {
return false;
}
break;
case DS.DX_YMN:
// Deal with the default long/short date format when the year number is NOT ambigous (i.e. year >= 100).
if (!dtfi.YearMonthAdjustment(ref raw.year, ref raw.month, true)) {
result.SetFailure(ParseFailureKind.FormatBadDateTimeCalendar, "Format_BadDateTimeCalendar", null);
return false;
}
if (!GetDayOfYMN(ref result, ref raw, dtfi)) {
return false;
}
break;
case DS.DX_NM:
case DS.DX_MN:
// Deal with Month/Day pattern.
GetDefaultYear(ref result, ref styles);
if (!dtfi.YearMonthAdjustment(ref result.Year, ref raw.month, true)) {
result.SetFailure(ParseFailureKind.FormatBadDateTimeCalendar, "Format_BadDateTimeCalendar", null);
return false;
}
if (!GetHebrewDayOfNM(ref result, ref raw, dtfi)) {
return false;
}
break;
case DS.DX_YM:
// Deal with Year/Month pattern.
if (!dtfi.YearMonthAdjustment(ref raw.year, ref raw.month, true)) {
result.SetFailure(ParseFailureKind.FormatBadDateTimeCalendar, "Format_BadDateTimeCalendar", null);
return false;
}
if (!GetDayOfYM(ref result, ref raw, dtfi)) {
return false;
}
break;
case DS.TX_N:
// Deal hour + AM/PM
if (!GetTimeOfN(dtfi, ref result, ref raw)) {
return false;
}
break;
case DS.TX_NN:
if (!GetTimeOfNN(dtfi, ref result, ref raw)) {
return false;
}
break;
case DS.TX_NNN:
if (!GetTimeOfNNN(dtfi, ref result, ref raw)) {
return false;
}
break;
default:
result.SetFailure(ParseFailureKind.Format, "Format_BadDateTime", null);
return false;
}
if (dps > DS.ERROR)
{
//
// We have reached a terminal state. Reset the raw num count.
//
raw.numCount = 0;
}
return true;
}
开发者ID:ChuangYang,项目名称:coreclr,代码行数:84,代码来源:DateTimeParse.cs
示例9: GetTypedDataSetSchema
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
DS ds = new DS();
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
any.Namespace = ds.Namespace;
sequence.Items.Add(any);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
开发者ID:TheNmonix,项目名称:inferenceengine,代码行数:44,代码来源:DS.Designer.cs
示例10: Fill
public virtual int Fill(DS.DesignActDataTable dataTable, string design) {
this.Adapter.SelectCommand = this.CommandCollection[0];
if ((design == null)) {
throw new global::System.ArgumentNullException("design");
}
else {
this.Adapter.SelectCommand.Parameters[0].Value = ((string)(design));
}
if ((this.ClearBeforeFill == true)) {
dataTable.Clear();
}
int returnValue = this.Adapter.Fill(dataTable);
return returnValue;
}
开发者ID:TheNmonix,项目名称:inferenceengine,代码行数:14,代码来源:DS.Designer.cs
示例11: Update
public virtual int Update(DS.CombinaisonDataTable dataTable) {
return this.Adapter.Update(dataTable);
}
开发者ID:TheNmonix,项目名称:inferenceengine,代码行数:3,代码来源:DS.Designer.cs
示例12: UpdateApps
public override DS.Web.UCenter.Api.ApiReturn UpdateApps(DS.Web.UCenter.UcApps apps)
{
throw new NotImplementedException();
}
开发者ID:zbw911,项目名称:MyFramework,代码行数:4,代码来源:UcApiDispose.cs
示例13: Lex
[System.Security.SecuritySafeCritical] // auto-generated
private static Boolean Lex(
#if !FEATURE_CORECLR
DS dps, ref __DTString str, ref DateTimeToken dtok, ref DateTimeRawInfo raw, ref DateTimeResult result, ref DateTimeFormatInfo dtfi, DateTimeStyles styles)
开发者ID:stormleoxia,项目名称:referencesource,代码行数:4,代码来源:datetimeparse.cs
示例14: Update
public abstract IDataReader Update(DS ds);
开发者ID:shhyder,项目名称:application,代码行数:1,代码来源:BaseNonParameter.cs
示例15: Insert
public abstract IDataReader Insert(DS ds);
开发者ID:shhyder,项目名称:application,代码行数:1,代码来源:BaseNonParameter.cs
示例16: UpdateBadWords
public override DS.Web.UCenter.Api.ApiReturn UpdateBadWords(DS.Web.UCenter.UcBadWords badWords)
{
throw new NotImplementedException();
}
开发者ID:zbw911,项目名称:MyFramework,代码行数:4,代码来源:UcApiDispose.cs
示例17: UpdateClient
public override DS.Web.UCenter.Api.ApiReturn UpdateClient(DS.Web.UCenter.UcClientSetting client)
{
throw new NotImplementedException();
}
开发者ID:zbw911,项目名称:MyFramework,代码行数:4,代码来源:UcApiDispose.cs
示例18: UpdateCreditSettings
public override DS.Web.UCenter.Api.ApiReturn UpdateCreditSettings(DS.Web.UCenter.UcCreditSettings creditSettings)
{
throw new NotImplementedException();
}
开发者ID:zbw911,项目名称:MyFramework,代码行数:4,代码来源:UcApiDispose.cs
示例19: GetTypedTableSchema
public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
DS ds = new DS();
global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
any1.Namespace = "http://www.w3.org/2001/XMLSchema";
any1.MinOccurs = new decimal(0);
any1.MaxOccurs = decimal.MaxValue;
any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any1);
global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
any2.MinOccurs = new decimal(1);
any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
sequence.Items.Add(any2);
global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute1.Name = "namespace";
attribute1.FixedValue = ds.Namespace;
type.Attributes.Add(attribute1);
global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
attribute2.Name = "tableTypeName";
attribute2.FixedValue = "ActionDataTable";
type.Attributes.Add(attribute2);
type.Particle = sequence;
global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
if (xs.Contains(dsSchema.TargetNamespace)) {
global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
try {
global::System.Xml.Schema.XmlSchema schema = null;
dsSchema.Write(s1);
for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
s2.SetLength(0);
schema.Write(s2);
if ((s1.Length == s2.Length)) {
s1.Position = 0;
s2.Position = 0;
for (; ((s1.Position != s1.Length)
&& (s1.ReadByte() == s2.ReadByte())); ) {
;
}
if ((s1.Position == s1.Length)) {
return type;
}
}
}
}
finally {
if ((s1 != null)) {
s1.Close();
}
if ((s2 != null)) {
s2.Close();
}
}
}
xs.Add(dsSchema);
return type;
}
开发者ID:TheNmonix,项目名称:inferenceengine,代码行数:60,代码来源:DS.Designer.cs
示例20: UpdateHosts
public override DS.Web.UCenter.Api.ApiReturn UpdateHosts(DS.Web.UCenter.UcHosts hosts)
{
throw new NotImplementedException();
}
开发者ID:zbw911,项目名称:MyFramework,代码行数:4,代码来源:UcApiDispose.cs
注:本文中的DS类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论