本文整理汇总了C#中DataTypes.ToCSharpFullName方法的典型用法代码示例。如果您正苦于以下问题:C# DataTypes.ToCSharpFullName方法的具体用法?C# DataTypes.ToCSharpFullName怎么用?C# DataTypes.ToCSharpFullName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DataTypes
的用法示例。
在下文中一共展示了DataTypes.ToCSharpFullName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GenerateCSharpSignature
public void GenerateCSharpSignature(DataTypes types, LrpStream stream)
{
if (this.Direction == ParameterDirection.InOut)
{
stream.Write("ref ");
}
else if (this.Direction == ParameterDirection.Out)
{
stream.Write("out ");
}
stream.Write("{0} {1}", types.ToCSharpFullName(this.Type), this.Name);
}
示例2: GenerateCSharpSignatureReader
public void GenerateCSharpSignatureReader(LrpStream stream, DataTypes types)
{
var typeFullname = types.ToCSharpFullName(this.Type);
stream.Write("{0} {1}", typeFullname, this.Name);
}
示例3: GenerateCSharpServerRequest
public void GenerateCSharpServerRequest(DataTypes types, LrpStream stream)
{
var type = this.Type;
stream.BeginLine();
stream.Write("var arg{0} = ", this.Id);
if (this.Direction == ParameterDirection.In || this.Direction == ParameterDirection.InOut)
{
stream.Write("buffer.Read{0}();", this.Type.Suffix);
}
else if (this.Direction == ParameterDirection.Out)
{
if (type == EmbeddedDataTypes.LocalPointer)
{
stream.Write("Lptr.Zero;");
}
else if (type == EmbeddedDataTypes.RemotePointer)
{
stream.Write("Rptr.Zero;");
}
else
{
stream.Write("default({0});", types.ToCSharpFullName(this.Type));
}
}
stream.EndLine();
}