DeveelDB  20151217
complete SQL database system, primarly developed for .NET/Mono frameworks
SpatialTypeResolver.cs
Go to the documentation of this file.
1 using System;
2 
3 using Deveel.Data.Types;
4 
5 namespace Deveel.Data.Spatial {
6  public sealed class SpatialTypeResolver : ITypeResolver {
8  try {
9  var srid = -1;
10  if (context.HasMeta("SRID")) {
11  var sridMeta = context.GetMeta("SRID");
12  srid = Convert.ToInt32(sridMeta.ToInt32());
13  }
14 
15  return new SpatialType(srid);
16  } catch (Exception) {
17  return null;
18  }
19  }
20  }
21 }
Defines the properties of a specific SQL Type and handles the values compatible.
Definition: SqlType.cs:33
SqlType ResolveType(TypeResolveContext context)