本文整理汇总了C#中Base类的典型用法代码示例。如果您正苦于以下问题:C# Base类的具体用法?C# Base怎么用?C# Base使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Base类属于命名空间,在下文中一共展示了Base类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Join
public Join(Base.IValidatePassphrase validatePassphrase, REPO.Game.Base.IJoin joinGame,
AS.GameRound.Base.IStart _startRound)
{
this._validatePassphrase = validatePassphrase;
this._joinGame = joinGame;
this._startRound = _startRound;
}
示例2: Main
public static void Main(string[] args)
{
var br = new BaseResult();
var dr = new DerivedResult();
var bas = new Base();
var derived = new Derived();
bas.Method();
bas.MethodWithParameter1(br);
bas.MethodWithParameter1(dr);
bas.MethodWithParameter2(dr);
bas = derived;
bas.Method();
bas.MethodWithParameter1(br);
bas.MethodWithParameter1(dr);
bas.MethodWithParameter2(dr);
derived.Method();
derived.MethodWithParameter1(br);
derived.MethodWithParameter1(dr);
derived.MethodWithParameter2(br);
derived.MethodWithParameter2(dr);
}
示例3: WindowsLogin
public WindowsLogin(Base.CommandHub parent)
: base(parent, "Windows - Login", new List<string> { "windows.login", "win.login", "net.login", "n.login" },
"-windows.login [ip] [domain/username] [password] [p|persistent] [ping]",
new List<string>() { @"-windows.login \\192.168.0.244\temp test testpw p",
@"-n.login 192.168.0.244 test testpw ping" })
{
}
示例4: FileFind
public FileFind(Base.CommandHub parent)
: base(parent, "File - Find",
new List<string> { "file.find", "f.f" },
"-file.find [filepattern]",
new List<string> { "-file.find \"*.vmdk\"" })
{
}
示例5: LabviewVersion
public LabviewVersion(Base.CommandHub parent)
: base(parent, "Set LabVIEW project version number",
new List<string> { "lv_ver" },
"-lv_ver [lvproj_file] [version]",
new List<string> { "-lv_ver \"*.lvproj_file\" \"1.0.2.1\"" })
{
}
示例6: CodeReIndent
public CodeReIndent(Base.CommandHub parent)
: base(parent, "Code - ReIndent",
new List<string> { "code.reindent", "c.reindent", "c.r" },
@"-code.reindent [filepath/pattern]",
new List<string> { "-code.reindent *.vb" })
{
}
示例7: Main
static void Main()
{
Base B = new Base();
Derived D = new Derived();
B.Message();
D.Message();
}
示例8: Main
static void Main()
{
Base bs = new Base();
SecondBase sb = new SecondBase();
bs.ShowInfo();
sb.ShowInfo();
}
示例9: FanucPositionsToCSV
public FanucPositionsToCSV(Base.CommandHub parent)
: base(parent, "Fanuc Export Positions",
new List<string> { "fanuc.ExportPositions", "fanuc.ExportPR" },
@"-fanuc.ExportPR <path to posreg.va>",
new List<string> { @"-fanuc.ExportPositions C:\Temp" })
{
}
示例10: FileEncode
public FileEncode(Base.CommandHub parent)
: base(parent, "File - Encode",
new List<string> { "file.encode", "f.e" },
"-file.encode [filepattern] [UTF7 | UTF8 | UTF32 | Unicode | BigEndianUnicode | ASCII]",
new List<string> { "-file.encode \"*.nsis\" utf8" })
{
}
示例11: GetGameCollectionRestfulConsume
public static GameBOCollection GetGameCollectionRestfulConsume()
{
GameBOCollection tempCollection = new GameBOCollection();
Base myBase = new Base();
using (WebClient webClient = new WebClient())
{
//Call REST service and get JSON response
string json = webClient.DownloadString("http://localhost:60706/LotteryService/Game/Collection/");
List<LotteryWindowsFormsApp.BO.GameDTO> gameCollectionList = myBase.GetGameList<LotteryWindowsFormsApp.BO.GameDTO>(json);
foreach (LotteryWindowsFormsApp.BO.GameDTO item in gameCollectionList)
{
if (!string.IsNullOrEmpty(item.GameName))
{
tempCollection.Add(new GameBO { GameId = item.GameId, GameName = item.GameName });
}
else
{
tempCollection.Add(new GameBO { GameId = item.GameId });
}
}
}
return tempCollection;
}
示例12: AssignCompound_1
async Task<bool> AssignCompound_1 ()
{
dynamic d = new Base ();
d.Value = 3;
d.Value += await Task.Factory.StartNew (() => 2);
return d.Value == 5;
}
示例13: Run
public void Run()
{
// Array Covariance
// http://msdn.microsoft.com/en-us/library/aa664572(v=vs.71).aspx
/*
* For any two reference-types A and B, if an implicit reference conversion (Section 6.1.4) or explicit reference conversion (Section 6.2.3)
* exists from A to B, then the same reference conversion also exists from the array type A[R] to the array type B[R],
* where R is any given rank-specifier (but the same for both array types).
* This relationship is known as array covariance.
* Array covariance in particular means that a value of an array type A[R] may actually be a reference to an instance of an array type B[R],
* provided an implicit reference conversion exists from B to A.
*
* Because of array covariance, assignments to elements of reference type arrays include a run-time check that ensures that the value
* being assigned to the array element is actually of a permitted type (Section 7.13.1).
* */
Base[] baseArray = new Base[1];
Derived[] derivedArray = new Derived[] { new Derived() };
// array element assignment is covariant
baseArray[0] = new Derived();
baseArray[0] = new OtherDerived();
// This assignment is not type safe but it is allowed
baseArray = derivedArray;
baseArray[0] = new Derived();
// ArrayTypeMismatchException at RUNTIME
baseArray[0] = new OtherDerived();
populate(derivedArray);
}
示例14: FileTimestamp
public FileTimestamp(Base.CommandHub parent)
: base(parent, "File - Timestamp Name",
new List<string> { "file.timestamp", "f.t", "timestamp", "t" },
@"-timestamp <FilePath> [date/time format]",
new List<string> { "-timestamp backup.zip \"yyyy.MM.dd-HH.mm\"" })
{
}
示例15: BuildSLN
public BuildSLN(Base.CommandHub parent)
: base(parent, "Build - .NET soultion",
new List<string> { "build.net", "b.net" },
"-b.net [.net version] [solution_path] [msbuild arguments]",
new List<string> { "-b.net 3.5 sar.sln /p:Configuration=Release /p:Platform=\"x86\"" })
{
}