本文整理汇总了C#中System.Data.SqlTypes.SqlDouble类的典型用法代码示例。如果您正苦于以下问题:C# SqlDouble类的具体用法?C# SqlDouble怎么用?C# SqlDouble使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SqlDouble类属于System.Data.SqlTypes命名空间,在下文中一共展示了SqlDouble类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: FillRow
public static void FillRow(object inputObject,
out SqlInt32 fileId,
out SqlString ctn,
out SqlString platform,
out SqlString platformId,
out SqlDouble frequency,
out DateTime timeStamp)
{
var row = (Row) inputObject;
fileId = row.FileId;
ctn = row.Collar.Ctn;
platform = row.Collar.Platform;
platformId = row.Collar.PlatformId;
frequency = row.Collar.Frequency;
timeStamp = row.Collar.TimeStamp;
}
开发者ID:regan-sarwas,项目名称:AnimalMovement,代码行数:16,代码来源:TfpSummerizer.cs
示例2: Accumulate
public void Accumulate(SqlDouble Value)
{
if (start)
{
min = Value;
max = Value;
start = false;
}
else
{
if (Value < min)
min = Value;
if (Value > max)
max = Value;
result = max - min;
}
}
开发者ID:MikE87,项目名称:sqlserver-extensions,代码行数:19,代码来源:MinToMax.cs
示例3: Accumulate
public void Accumulate(SqlDouble input)
{
if (input.IsNull != true)
{
doubleList.Add(input.Value);
}
}
开发者ID:JustinRoll,项目名称:SqlServerUtilities,代码行数:7,代码来源:Median.cs
示例4: String_Distances_Filler
public static void String_Distances_Filler(object distances,
out SqlString fromString, out SqlString toString, out SqlDouble Hamming_Distance,
out SqlDouble Jaccard_Distance, out SqlDouble Jaro_Distance, out SqlDouble Jaro_Winkler_Distance,
out SqlDouble Levenshtein_Distance, out SqlDouble Levenshtein_Distance_Lower_Bound,
out SqlDouble Levenshtein_Distance_Upper_Bound, out SqlDouble Normalized_Levenshtein_Distance,
out SqlDouble Overlap_Coefficient, out SqlDouble Ratcliff_Obershelp_Similarity,
out SqlDouble Sorensen_Dice_Index, out SqlDouble Sorensen_Dice_Distance,
out SqlDouble Tanimoto_Coefficient) {
AllDistanceMetrics adm = (AllDistanceMetrics)distances;
fromString = adm.fromString;
toString = adm.toString;
Hamming_Distance = adm.Hamming_Distance;
Jaccard_Distance = adm.Jaccard_Distance;
Jaro_Distance = adm.Jaro_Distance;
Jaro_Winkler_Distance = adm.Jaro_Winkler_Distance;
Levenshtein_Distance = adm.Levenshtein_Distance;
Levenshtein_Distance_Lower_Bound = adm.Levenshtein_Distance_Lower_Bound;
Levenshtein_Distance_Upper_Bound = adm.Levenshtein_Distance_Upper_Bound;
Normalized_Levenshtein_Distance = adm.Normalized_Levenshtein_Distance;
Overlap_Coefficient = adm.Overlap_Coefficient;
Ratcliff_Obershelp_Similarity = adm.Ratcliff_Obershelp_Similarity;
Sorensen_Dice_Index = adm.Sorensen_Dice_Index;
Sorensen_Dice_Distance = adm.Sorensen_Dice_Distance;
Tanimoto_Coefficient = adm.Tanimoto_Coefficient;
}
开发者ID:wbuchanan,项目名称:whyWontSQLServerImplementRegexNatively,代码行数:26,代码来源:AllDistanceMetrics.cs
示例5: Accumulate
public void Accumulate(SqlDouble Value)
{
if(Value.IsNull == false)
{
_sum += Value.Value;
}
}
开发者ID:ben-thul,项目名称:SQLCLR,代码行数:7,代码来源:SmarterSum.cs
示例6: GetImageBound
public static SqlGeometry GetImageBound(SqlDouble Longitude, SqlDouble Latitude, SqlInt32 Width, SqlInt32 Height,
SqlDouble Zoom, SqlInt32 PixelYOffset)
{
long cpX, cpY, LeftTopX, LeftTopY, RightBottomX, RightBottomY;
long halfWidth = ((long) Width) >> 1;
long halfHeight = ((long) Height) >> 1;
double dZoom = (double) Zoom;
// получить центральный пиксел по коорд
cpX = (long) FromLongitudeToXPixel(Longitude, Zoom);
cpY = (long) (FromLatitudeToYPixel(Latitude, Zoom) + PixelYOffset);
LeftTopX = cpX - halfWidth;
LeftTopY = cpY - halfHeight;
RightBottomX = cpX + halfWidth;
RightBottomY = cpY + halfHeight;
double Lat1, Lon1, Lat2, Lon2;
Lat1 = FromYPixelToLat(LeftTopY, dZoom);
Lon1 = FromXPixelToLon(LeftTopX, dZoom);
Lat2 = FromYPixelToLat(RightBottomY, dZoom);
Lon2 = FromXPixelToLon(RightBottomX, dZoom);
//
var geomBuilder = new SqlGeometryBuilder();
geomBuilder.SetSrid((0));
geomBuilder.BeginGeometry(OpenGisGeometryType.Polygon);
geomBuilder.BeginFigure(Lon1, Lat1);
geomBuilder.AddLine(Lon1, Lat2);
geomBuilder.AddLine(Lon2, Lat2);
geomBuilder.AddLine(Lon2, Lat1);
geomBuilder.AddLine(Lon1, Lat1);
geomBuilder.EndFigure();
geomBuilder.EndGeometry();
return geomBuilder.ConstructedGeometry;
}
开发者ID:MoonDav,项目名称:TileRendering,代码行数:33,代码来源:SqlCoordsTileConversion.cs
示例7: Accumulate
public void Accumulate(SqlDouble Value)
{
if (Value.IsNull == false)
{
_list.Add(Value.Value);
}
}
开发者ID:ben-thul,项目名称:SQLCLR,代码行数:7,代码来源:NaiveSum.cs
示例8: Box
public static object Box(SqlDouble a)
{
if (a.IsNull)
return null;
else
return a.Value;
}
开发者ID:valery-shinkevich,项目名称:sooda,代码行数:7,代码来源:SoodaNullable.cs
示例9: Create
public void Create ()
{
SqlDouble Test = new SqlDouble ((double) 34.87);
Assert.AreEqual (34.87D, Test.Value, "#A01");
Test = new SqlDouble (-9000.6543);
Assert.AreEqual (-9000.6543D, Test.Value, "#A02");
}
开发者ID:tohosnet,项目名称:Mono.Data.Sqlite,代码行数:8,代码来源:SqlDoubleTest.cs
示例10: Create
public void Create()
{
SqlDouble Test = new SqlDouble(34.87);
Assert.Equal(34.87D, Test.Value);
Test = new SqlDouble(-9000.6543);
Assert.Equal(-9000.6543D, Test.Value);
}
开发者ID:dotnet,项目名称:corefx,代码行数:8,代码来源:SqlDoubleTest.cs
示例11: Create
public void Create()
{
SqlDouble Test= new SqlDouble ((double)34.87);
AssertEquals ("#A01", 34.87D, Test.Value);
Test = new SqlDouble (-9000.6543);
AssertEquals ("#A02", -9000.6543D, Test.Value);
}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:8,代码来源:SqlDoubleTest.cs
示例12: FromLatitudeToYPixel
public static SqlInt64 FromLatitudeToYPixel(SqlDouble Latitude, SqlDouble zoomLevel)
{
var pixelGlobeSize = PixelTileSize*Math.Pow(2.0, (double) zoomLevel);
var f = Math.Min(Math.Max(Math.Sin((double) (Latitude*RadiansToDegreesRatio)), -0.9999d), 0.9999d);
var y =
Math.Round(Convert.ToSingle(pixelGlobeSize/2d) +
.5d*Math.Log((1d + f)/(1d - f))*-(pixelGlobeSize/(2d*Math.PI)));
return Convert.ToInt64(y);
}
开发者ID:MoonDav,项目名称:TileRendering,代码行数:9,代码来源:SqlCoordsTileConversion.cs
示例13: Properties
public void Properties()
{
SqlDouble Test5443 = new SqlDouble (5443e12);
SqlDouble Test1 = new SqlDouble (1);
Assert ("#C01", SqlDouble.Null.IsNull);
AssertEquals ("#C02", 5443e12, Test5443.Value);
AssertEquals ("#C03", (double)1, Test1.Value);
}
开发者ID:jjenki11,项目名称:blaze-chem-rendering,代码行数:9,代码来源:SqlDoubleTest.cs
示例14: Properties
public void Properties()
{
SqlDouble Test5443 = new SqlDouble(5443e12);
SqlDouble Test1 = new SqlDouble(1);
Assert.True(SqlDouble.Null.IsNull);
Assert.Equal(5443e12, Test5443.Value);
Assert.Equal(1, Test1.Value);
}
开发者ID:dotnet,项目名称:corefx,代码行数:9,代码来源:SqlDoubleTest.cs
示例15: Properties
public void Properties ()
{
SqlDouble Test5443 = new SqlDouble (5443e12);
SqlDouble Test1 = new SqlDouble (1);
Assert.IsTrue (SqlDouble.Null.IsNull, "#C01");
Assert.AreEqual (5443e12, Test5443.Value, "#C02");
Assert.AreEqual ((double) 1, Test1.Value, "#C03");
}
开发者ID:tohosnet,项目名称:Mono.Data.Sqlite,代码行数:9,代码来源:SqlDoubleTest.cs
示例16: Accumulate
public void Accumulate(SqlDouble Value)
{
// normalise value, divide by 100
Value = System.Data.SqlTypes.SqlDouble.Divide(Value, new SqlDouble(100));
// -x
var negated = System.Data.SqlTypes.SqlDouble.Multiply(new SqlDouble(-1),Value);
// 1-x
var oneMinus = System.Data.SqlTypes.SqlDouble.Add(new SqlDouble(1), negated);
complementProduct = System.Data.SqlTypes.SqlDouble.Multiply(complementProduct, oneMinus);
}
开发者ID:GmailYan,项目名称:ProbabilisticDatabase,代码行数:10,代码来源:IndependentProject.cs
示例17: BuildMultipolygonSimplified
/// <summary>
/// Builds multipoligon by each polygon inside geometry collection
/// </summary>
public static void BuildMultipolygonSimplified(SqlGeometryBuilder builder, SqlGeometry shape,
SqlDouble shortestDistance)
{
builder.BeginGeometry(OpenGisGeometryType.MultiPolygon);
var polygonCount = shape.STNumGeometries();
for (int i = 1; i <= polygonCount; i++)
{
BuildPolygonSimplified(builder, shape.STGeometryN(i), shortestDistance);
}
// End the geometry
builder.EndGeometry();
}
开发者ID:MoonDav,项目名称:TileRendering,代码行数:15,代码来源:ShortLineExcluding.cs
示例18: Accumulate
public void Accumulate(SqlDouble FirstValue, SqlDouble SecondValue)
{
// Put your code here
if (FirstValue.IsNull != true && SecondValue.IsNull != true)
{
this.firstList.Add(FirstValue.Value);
this.sumOfFirst += Convert.ToDecimal(FirstValue.Value);
this.secondList.Add(SecondValue.Value);
this.sumOfSecond += Convert.ToDecimal(SecondValue.Value);
}
}
开发者ID:JustinRoll,项目名称:SqlServerUtilities,代码行数:12,代码来源:Covariance.cs
示例19: GetEventData_FillRow
public static void GetEventData_FillRow(object source, out SqlInt32 seriesID, out SqlString characteristic, out DateTime time, out SqlDouble value)
{
DataPoint dataPoint = source as DataPoint;
if ((object)dataPoint == null)
throw new InvalidOperationException("FillRow source is not a DataPoint");
seriesID = dataPoint.SeriesID;
characteristic = dataPoint.Characteristic;
time = dataPoint.Time;
value = ToSqlDouble(dataPoint.Value);
}
开发者ID:GridProtectionAlliance,项目名称:openXDA,代码行数:12,代码来源:XDAFunctions.cs
示例20: Accumulate
public void Accumulate(SqlDouble FirstValue, SqlDouble SecondValue)
{
// Put your code here
if (FirstValue.IsNull != true && SecondValue.IsNull != true)
{
this.sumOfSquaresOfFirst += Convert.ToDecimal(FirstValue.Value) * Convert.ToDecimal(FirstValue.Value);
this.sumOfSquaresOfSecond += Convert.ToDecimal(SecondValue.Value) * Convert.ToDecimal(SecondValue.Value);
this.sumOfFirst += Convert.ToDecimal(FirstValue.Value);
this.sumOfSecond += Convert.ToDecimal(SecondValue.Value);
this.coProduct += Convert.ToDecimal(FirstValue.Value) * Convert.ToDecimal(SecondValue.Value);
this.numberOfRecords++;
}
}
开发者ID:JustinRoll,项目名称:SqlServerUtilities,代码行数:13,代码来源:Pearsons.cs
注:本文中的System.Data.SqlTypes.SqlDouble类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论