Skip to content

Commit

Permalink
Merge pull request #50 from ossimlabs/OP-15
Browse files Browse the repository at this point in the history
Op 15
  • Loading branch information
sbortman authored Aug 20, 2019
2 parents bb6028d + d7a3694 commit ff106cc
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ class OmarGeoScriptBootStrap
new JsonSlurper().parseText(it.geoJSON)
}

/*
Function.registerFunction( "queryCollection" ) { String layerName, String attributeName, String filter ->
def (workspace, layer) = getWorkspaceAndLayer( layerName )
def results = layer?.collectFromFeature( filter ) { it[attributeName] }
Expand All @@ -52,8 +51,6 @@ class OmarGeoScriptBootStrap

Class.forName( multiType ).newInstance( geometries )
}
*/

}

def destroy = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ class GeoscriptService implements InitializingBean
@Override
void afterPropertiesSet() throws Exception
{
/*
// Thread.start {
Function.registerFunction( "queryCollection" ) { String layerName, String attributeName, String filter ->
def (workspace, layer) = getWorkspaceAndLayer( layerName )
Expand All @@ -216,7 +217,7 @@ class GeoscriptService implements InitializingBean
Class.forName( multiType ).newInstance( geometries )
}
// }

*/
defaultMaxFeatures = grailsApplication.config.geoscript.defaultMaxFeatures as Integer
}

Expand Down Expand Up @@ -488,6 +489,17 @@ class GeoscriptService implements InitializingBean

def queryLayer(String typeName, Map<String,Object> options, String resultType='results', String featureFormat=null, Boolean includeNumberMatched=null)
{
def info = [
name: 'queryLayer',
typeName: typeName,
options: options,
resultType: resultType,
featureFormat: featureFormat,
includeNumberMatched: includeNumberMatched
]

log.info( info as String )

def requestType = "GET"
def requestMethod = "QueryLayer"
Date startTime = new Date()
Expand Down

0 comments on commit ff106cc

Please sign in to comment.