Albert, you can quickly create own utility, like this:package ee.alphagis.utils
{
public class SPUtils
{
/**
* @param wkid Well-known ID
* @return spatial reference <b>Well-known Text</b> by input Well-known ID, or <b>null</b> if not found
*/
public static function returnTextById(wkid:Number):String
{
var result:String = null;
switch (wkid)
{
case 3819:
{
result = "GEOGCS[\"GCS_HD1909\",DATUM[\"D_Hungarian_Datum_1909\",SPHEROID[\"Bessel_1841\",6377397.155,299.1528128]],PRIMEM[\"Greenwich\",0.0],UNIT[\"Degree\",0.0174532925199433]]"
break;
}
case 3821:
{
result = "GEOGCS[\"GCS_TWD_1967\",DATUM[\"D_TWD_1967\",SPHEROID[\"GRS_1967_Truncated\",6378160.0,298.25]],PRIMEM[\"Greenwich\",0.0],UNIT[\"Degree\",0.0174532925199433]]";
break;
}
//TODO: add needed cases here
default:
{
break;
}
}
return result;
}
/**
* @param wkid Well-known ID
* @return spatial reference <b>name</b> by input Well-known ID, or <b>null</b> if not found
*/
public static function returnNameById(wkid:Number):String
{
var result:String = null;
switch (wkid)
{
case 3819:
{
result = "GCS_HD1909"
break;
}
case 3821:
{
result = "GCS_TWD_1967";
break;
}
//TODO: add needed cases here
default:
{
break;
}
}
return result;
}
/**
* @param wkid Well-known ID
* @return spatial reference <b>Well-known Text</b> by input name, or <b>null</b> if not found
*/
public static function returnTextByName(name:String):String
{
var result:String = null;
switch (name)
{
case "GCS_HD1909":
{
result = "GEOGCS[\"GCS_HD1909\",DATUM[\"D_Hungarian_Datum_1909\",SPHEROID[\"Bessel_1841\",6377397.155,299.1528128]],PRIMEM[\"Greenwich\",0.0],UNIT[\"Degree\",0.0174532925199433]]"
break;
}
case "GCS_TWD_1967":
{
result = "GEOGCS[\"GCS_TWD_1967\",DATUM[\"D_TWD_1967\",SPHEROID[\"GRS_1967_Truncated\",6378160.0,298.25]],PRIMEM[\"Greenwich\",0.0],UNIT[\"Degree\",0.0174532925199433]]";
break;
}
//TODO: add needed cases here
default:
{
break;
}
}
return result;
}
}
}
it based on coordinate systems id's reference, published by ESRI team