Esri Geoportal Server
1.0

com.esri.gpt.catalog.harvest.repository
Class HrAssertUrlRequest

java.lang.Object
  extended by com.esri.gpt.framework.sql.BaseDao
      extended by com.esri.gpt.framework.request.DaoRequest<RequestDefinition<HrCriteria,HrResult>>
          extended by com.esri.gpt.catalog.harvest.repository.HrRequest
              extended by com.esri.gpt.catalog.harvest.repository.HrAssertUrlRequest
All Implemented Interfaces:
IRequest<RequestDefinition<HrCriteria,HrResult>>

public class HrAssertUrlRequest
extends HrRequest

Asserts unique URL.


Constructor Summary
HrAssertUrlRequest(RequestContext requestContext, String url)
          Create instance of the request.
 
Method Summary
 boolean execute()
          Executes request.
 void executeAssert()
          Executes assertion.
 
Methods inherited from class com.esri.gpt.catalog.harvest.repository.HrRequest
getActionCriteria, getActionResult, getHarvestingDataTableName, getHarvestingHistoryTableName, getHarvestingJobsCompletedTableName, getHarvestingJobTableName, getHarvestingTableName, getQueryCriteria, getQueryResult
 
Methods inherited from class com.esri.gpt.framework.request.DaoRequest
getRequestDefinition, setRequestDefinition
 
Methods inherited from class com.esri.gpt.framework.sql.BaseDao
appendExpression, appendValueFilter, closeResultSet, closeStatement, getApplicationConfiguration, getRequestContext, logExpression, returnConnection, setRequestContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HrAssertUrlRequest

public HrAssertUrlRequest(RequestContext requestContext,
                          String url)
Create instance of the request.

Parameters:
requestContext - request context
url - URL to assert
Method Detail

executeAssert

public void executeAssert()
                   throws SQLException,
                          HrAssertUrlException
Executes assertion.

Throws:
SQLException - if accessing database fails
HrAssertUrlException - if record with the same URL already exist in database

execute

public boolean execute()
                throws SQLException
Executes request.

Returns:
true if record with identical host URL exists
Throws:
SQLException - if accessing database fails

Esri Geoportal Server
1.0

Copyright 2011 Environmental Systems Research Institute. All rights reserved. Use is subject to license terms.