本文整理汇总了C#中Fields.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# Fields.ToString方法的具体用法?C# Fields.ToString怎么用?C# Fields.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Fields
的用法示例。
在下文中一共展示了Fields.ToString方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: IncreaseField
public void IncreaseField(Fields field, float val)
{
if(javaUnityApplicasaDataManager==null)
javaUnityApplicasaDataManager = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaDataManager");
javaUnityApplicasaDataManager.CallStatic("ApplicasaDataManagerIncreaseFieldFloat", innerDataManagerJavaObject, (int)field, field.ToString(), val);
}
示例2: CheckValue
/// <summary>
/// If field is an enum, make sure the value is valid.
/// </summary>
/// <param name="field"></param>
public void CheckValue(Fields.IField field)
{
DDField fld = FieldsByTag[ field.Tag ];
if( fld.HasEnums() )
if( fld.IsMultipleValueFieldWithEnums )
{
string [] splitted = field.ToString().Split( ' ' );
foreach( string value in splitted )
if( !fld.EnumDict.ContainsKey( value ) )
throw new IncorrectTagValue( field.Tag );
}
else if( !fld.EnumDict.ContainsKey( field.ToString() ) )
throw new IncorrectTagValue( field.Tag );
}
示例3: AddOrder
public void AddOrder(Fields field, SortType sortType)
{
if(javaUnityApplicasaQuery==null)
javaUnityApplicasaQuery = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaQuery");
javaUnityApplicasaQuery.CallStatic("ApplicasaQueryAddOrder", innerQueryJavaObject, (int)field, field.ToString(), (int)sortType);
}
示例4: SetGeoFilter
public void SetGeoFilter(Fields field, Location location, int radius)
{
if(javaUnityApplicasaQuery==null)
javaUnityApplicasaQuery = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaQuery");
javaUnityApplicasaQuery.CallStatic("ApplicasaQuerySetGeoFilter", innerQueryJavaObject, (int)field, field.ToString(), location.Latitude, location.Longitude, radius);
}
示例5: IncreaseField
public void IncreaseField(Fields field, float val)
{
if(javaUnityApplicasaColors==null)
javaUnityApplicasaColors = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaColors");
javaUnityApplicasaColors.CallStatic("ApplicasaColorsIncreaseFieldFloat", innerColorsJavaObject, (int)field, field.ToString(), val);
}
示例6: GetFilter
public static Filter GetFilter(Fields field, OPERATORS op, bool val)
{
if(javaUnityApplicasaFilter==null)
javaUnityApplicasaFilter = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaFilter");
AndroidJavaObject tempJavaObject=javaUnityApplicasaFilter.CallStatic<AndroidJavaObject>("ApplicasaFilterGetFilterBool", (int)field, field.ToString(), (int)op, val);
Filter filter = new Filter(tempJavaObject.GetRawObject(), tempJavaObject);
return filter;
}
示例7: IncreaseField
public void IncreaseField(Fields field, float val)
{
if(javaUnityApplicasaVirtualGoodCategory==null)
javaUnityApplicasaVirtualGoodCategory = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaVirtualGoodCategory");
javaUnityApplicasaVirtualGoodCategory.CallStatic("ApplicasaVirtualGoodCategoryIncreaseFieldFloat", innerVirtualGoodCategoryJavaObject, (int)field, field.ToString(), val);
}
示例8: CheckValidFormat
/// <summary>
/// Check that the field contents match the DataDictionary-defined type
/// </summary>
/// <param name="field"></param>
public void CheckValidFormat(Fields.IField field)
{
try
{
Type type;
if (!TryGetFieldType(field.Tag, out type))
return;
if (type.Equals(typeof(Fields.StringField)))
return;
else if (type.Equals(typeof(Fields.CharField)))
Fields.Converters.CharConverter.Convert(field.ToString());
else if (type.Equals(typeof(Fields.IntField)))
Fields.Converters.IntConverter.Convert(field.ToString());
else if (type.Equals(typeof(Fields.DecimalField)))
Fields.Converters.DecimalConverter.Convert(field.ToString());
else if (type.Equals(typeof(Fields.BooleanField)))
Fields.Converters.BoolConverter.Convert(field.ToString());
else if (type.Equals(typeof(Fields.DateTimeField)))
Fields.Converters.DateTimeConverter.ConvertToDateTime(field.ToString());
else if (type.Equals(typeof(Fields.DateOnlyField)))
Fields.Converters.DateTimeConverter.ConvertToDateOnly(field.ToString());
else if (type.Equals(typeof(Fields.TimeOnlyField)))
Fields.Converters.DateTimeConverter.ConvertToTimeOnly(field.ToString());
return;
}
catch (FieldConvertError e)
{
throw new IncorrectDataFormat(field.Tag, e);
}
}
示例9: addToOnlineUpdates
private void addToOnlineUpdates(Fields key, Object val)
{
dictionary[key.ToString()] = JToken.FromObject(val);
}
示例10: IncreaseField
public void IncreaseField(Fields field, int val)
{
if(javaUnityApplicasaDataManString==null)
javaUnityApplicasaDataManString = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaDataManString");
javaUnityApplicasaDataManString.CallStatic("ApplicasaDataManStringIncreaseFieldInt", innerDataManStringJavaObject, (int)field, field.ToString(), val);
}
示例11: GetFilter
public static Filter GetFilter(Fields field, OPERATORS op, string val)
{
if(javaUnityApplicasaFilter==null)
javaUnityApplicasaFilter = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaFilter");
AndroidJavaObject tempJavaObject=javaUnityApplicasaFilter.CallStatic<AndroidJavaObject>("ApplicasaFilterGetFilterString", (int)field, field.ToString(), (int)op, val);
IntPtr tempIntPtr = AndroidJNI.NewGlobalRef(tempJavaObject.GetRawObject());
Filter filter = new Filter(tempIntPtr, new AndroidJavaObject(tempIntPtr));
return filter;
}
示例12: UploadFile
public void UploadFile(byte[] data, Fields field, AMAZON_FILE_TYPES fileType, string extension, Action action)
{
int uniqueActionID=Core.currentCallbackID;
Core.currentCallbackID++;
Core.setActionCallback(action,uniqueActionID);
javaUnityApplicasaUser.CallStatic("ApplicasaUserUploadFile", innerUserJavaObject, (int)field, field.ToString(), AndroidJNI.ToByteArray(data), data.Length, fileType, extension, uniqueActionID);
}
示例13: IncreaseField
public void IncreaseField(Fields field, float val)
{
javaUnityApplicasaUser.CallStatic("ApplicasaUserIncreaseFieldFloat", innerUserJavaObject, (int)field, field.ToString(), val);
}
示例14: IncreaseField
public void IncreaseField(Fields field, int val)
{
if(javaUnityApplicasaChat==null)
javaUnityApplicasaChat = new AndroidJavaClass("com.applicasaunity.Unity.ApplicasaChat");
javaUnityApplicasaChat.CallStatic("ApplicasaChatIncreaseFieldInt", innerChatJavaObject, (int)field, field.ToString(), val);
}
示例15: GetLocator
protected string GetLocator(Fields ccVerifFields, LocatorType locatorType)
{
string locator = string.Empty;
string baseLocator = "//*[@id='{0}{1}']{2}";
string forType = string.Empty;
string forField = ccVerifFields.ToString();
InputType inputType = GetInputType(ccVerifFields);
switch (inputType)
{
case InputType.Dropdown:
forType = "ddl";
break;
case InputType.Textbox:
forType = "txt";
break;
case InputType.Checkbox:
forType = "chk";
break;
}
switch (locatorType)
{
case LocatorType.Edit:
locator = string.Format(baseLocator, forType, forField, string.Empty);
break;
case LocatorType.Label:
if (inputType == InputType.Checkbox)
locator = string.Format(baseLocator, forType, forField, "/../label");
else
locator = string.Format(baseLocator, forType, forField, "/../../td[1]");
break;
}
return locator;
}