Skip to content

Commit

Permalink
remove security module
Browse files Browse the repository at this point in the history
  • Loading branch information
chinadragon0515 committed Aug 2, 2016
1 parent 7fb6c6d commit 6b061d8
Show file tree
Hide file tree
Showing 22 changed files with 26 additions and 1,139 deletions.
10 changes: 0 additions & 10 deletions RESTier.sln
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Core", "Core", "{3F748477-9
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Restier.Core", "src\Microsoft.Restier.Core\Microsoft.Restier.Core.csproj", "{F1BEAB8D-82D4-4BBB-A5C6-BA0E6872E508}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Modules", "Modules", "{8C1F84BA-3888-4FC5-A286-506A11C54463}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Restier.Security", "src\Microsoft.Restier.Security\Microsoft.Restier.Security.csproj", "{B15A5064-F0D2-480C-A51E-3430A8360827}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Providers", "Providers", "{0355FEC8-17CF-44B4-9D24-685266A349FB}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Publishers", "Publishers", "{432208D4-54DF-453E-96AE-CB7721461030}"
Expand Down Expand Up @@ -53,10 +49,6 @@ Global
{F1BEAB8D-82D4-4BBB-A5C6-BA0E6872E508}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F1BEAB8D-82D4-4BBB-A5C6-BA0E6872E508}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F1BEAB8D-82D4-4BBB-A5C6-BA0E6872E508}.Release|Any CPU.Build.0 = Release|Any CPU
{B15A5064-F0D2-480C-A51E-3430A8360827}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B15A5064-F0D2-480C-A51E-3430A8360827}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B15A5064-F0D2-480C-A51E-3430A8360827}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B15A5064-F0D2-480C-A51E-3430A8360827}.Release|Any CPU.Build.0 = Release|Any CPU
{D1F0FA28-73A1-4202-807B-DCAF5FFEDC2F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D1F0FA28-73A1-4202-807B-DCAF5FFEDC2F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D1F0FA28-73A1-4202-807B-DCAF5FFEDC2F}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down Expand Up @@ -108,8 +100,6 @@ Global
GlobalSection(NestedProjects) = preSolution
{3F748477-9CDD-485C-A885-1FEC14A24331} = {D5E947EB-03CB-4D04-8937-FF2131BB1F04}
{F1BEAB8D-82D4-4BBB-A5C6-BA0E6872E508} = {3F748477-9CDD-485C-A885-1FEC14A24331}
{8C1F84BA-3888-4FC5-A286-506A11C54463} = {D5E947EB-03CB-4D04-8937-FF2131BB1F04}
{B15A5064-F0D2-480C-A51E-3430A8360827} = {8C1F84BA-3888-4FC5-A286-506A11C54463}
{0355FEC8-17CF-44B4-9D24-685266A349FB} = {D5E947EB-03CB-4D04-8937-FF2131BB1F04}
{432208D4-54DF-453E-96AE-CB7721461030} = {D5E947EB-03CB-4D04-8937-FF2131BB1F04}
{D1F0FA28-73A1-4202-807B-DCAF5FFEDC2F} = {552DD8A7-2F3A-4D0F-B623-B7D832C6C62B}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,15 @@ namespace Microsoft.Restier.Providers.EntityFramework.Spatial
/// </summary>
public static class GeographyConverter
{
private static readonly CultureInfo DefaultCulture = CultureInfo.GetCultureInfo("En-Us");
private const string GeographyTypeNamePoint = "Point";
private const string GeographyTypeNameLineString = "LineString";
private static readonly CultureInfo DefaultCulture = CultureInfo.GetCultureInfo("En-Us");

/// <summary>
/// Convert a DbGeography to Edm GeographyPoint
/// </summary>
/// <param name="geography"> The DbGeography to be converted</param>
/// <returns>A Edm GeographyPoint</returns>
public static GeographyPoint ToGeographyPoint(this DbGeography geography)
{
if (geography == null)
Expand All @@ -42,6 +47,11 @@ public static GeographyPoint ToGeographyPoint(this DbGeography geography)
return GeographyPoint.Create(lat, lon, alt, m);
}

/// <summary>
/// Convert a Edm GeographyPoint to DbGeography
/// </summary>
/// <param name="point">The Edm GeographyPoint to be converted</param>
/// <returns>A DbGeography</returns>
public static DbGeography ToDbGeography(this GeographyPoint point)
{
if (point == null)
Expand All @@ -67,6 +77,11 @@ public static DbGeography ToDbGeography(this GeographyPoint point)
return DbGeography.FromText(text);
}

/// <summary>
/// Convert a DbGeography to Edm GeographyPoint
/// </summary>
/// <param name="geography"> The DbGeography to be converted</param>
/// <returns>A Edm GeographyLineString</returns>
public static GeographyLineString ToGeographyLineString(this DbGeography geography)
{
if (geography == null)
Expand All @@ -91,12 +106,14 @@ public static GeographyLineString ToGeographyLineString(this DbGeography geograp
if (numPoints > 0)
{
DbGeography point = geography.PointAt(1);
pipleLine.BeginFigure(new GeographyPosition(point.Latitude ?? 0, point.Latitude ?? 0, point.Elevation, point.Measure));
pipleLine.BeginFigure(new GeographyPosition(
point.Latitude ?? 0, point.Latitude ?? 0, point.Elevation, point.Measure));

for (int n = 2; n <= numPoints; n++)
{
point = geography.PointAt(n);
pipleLine.LineTo(new GeographyPosition(point.Latitude ?? 0, point.Latitude ?? 0, point.Elevation, point.Measure));
pipleLine.LineTo(new GeographyPosition(
point.Latitude ?? 0, point.Latitude ?? 0, point.Elevation, point.Measure));
}

pipleLine.EndFigure();
Expand All @@ -107,6 +124,11 @@ public static GeographyLineString ToGeographyLineString(this DbGeography geograp
return lineString;
}

/// <summary>
/// Convert a Edm GeographyLineString to DbGeography
/// </summary>
/// <param name="lineString">The Edm GeographyLineString to be converted</param>
/// <returns>A DbGeography</returns>
public static DbGeography ToDbGeography(this GeographyLineString lineString)
{
if (lineString == null)
Expand Down Expand Up @@ -142,6 +164,7 @@ public static DbGeography ToDbGeography(this GeographyLineString lineString)
sb.Append(",");
}
}

sb.Append(")");

return DbGeography.FromText(sb.ToString());
Expand Down
41 changes: 0 additions & 41 deletions src/Microsoft.Restier.Security/ApiConfigurationExtensions.cs

This file was deleted.

145 changes: 0 additions & 145 deletions src/Microsoft.Restier.Security/ApiPermission.cs

This file was deleted.

46 changes: 0 additions & 46 deletions src/Microsoft.Restier.Security/ApiPermissionType.cs

This file was deleted.

Loading

0 comments on commit 6b061d8

Please sign in to comment.