Packagecom.esri.baserver.tasks.reports
Classpublic class LocatorReportParameters
InheritanceLocatorReportParameters Inheritance AnalysisAndReportParameters Inheritance StandardReportParameters Inheritance BATaskParameters Inheritance Object

The LocatorReportParameters class provides input parameters for the Locator Report task.

The analysis can be restricted to an analysis extent if the analysisExtent parameter is specified. Optional singleStoreID parameter restricts the analysis to a single store.

The businessesSearchMethod parameter specifies the algorithm for selecting the business points nearest to every store location:

ValueDescription
BusinessesSearchMethod.FIND_CLOSEST Selects not more closest business points than the given number specified with the closestBusinessesCount parameter.
BusinessesSearchMethod.WITHIN_RANGE Selects all business points that fall within a predefined distance specified with the nearestDistance and nearestDistanceUnits parameters. For example, you can select all business points that are within five miles of each store location.

The calculationMethod parameter specifies a method for distance calculation from within drive time, drive distance, or straight-line distance variants.

The locator report can be generated in the portrait or landscape mode specified with the reportOrientation parameter. In the portrait mode, the number of attributes of business points shown in columns is limited to 4. In the landscape mode, up to 6 attributes of business points can be shown. The attribute fields of the business layer to be exported to the report and their alias names to be shown in captions of columns are specified with the fieldNames and fieldAliases parameter, respectively.

Output options for this task include rendering an output image (outputTypes.getMapImage), creating a feature class for subsequent analysis (outputTypes.getFeatureClass), and/or creating a report (outputTypes.getReport). If no output options are specified, the required output options are specified as follows. If the renderingParameters parameter is specified, the image output is requested. If the standardReportOptions parameter is specified, the report is requested. If the outputAnalysisItem parameter is specified, the output analysis feature class will be stored in the repository. If renderingParameters, standardReportOptions, and outputAnalysisItem parameters are missing, the feature class output is requested.

View the examples

See also

LocatorReportTask


Public Properties
 PropertyDefined By
 InheritedactiveDatasetID : String
Active dataset ID.
BATaskParameters
  analysisExtent : Geometry
Spatial/geographic extent to restrict analysis by.
LocatorReportParameters
  businessesSearchMethod : BusinessesSearchMethod
Method to search for the closest competitors.
LocatorReportParameters
  businessPoints : PointLayer
Point layer with competitors' business points (requred).
LocatorReportParameters
  calculationMethod : DistanceCalcType
Distance calculation method.
LocatorReportParameters
  closestBusinessesCount : int
Closest businesses count threshold.
LocatorReportParameters
  distanceUnits : String
Units to report distances in.
LocatorReportParameters
  fieldAliases : Array
Aliases of fields to be shown in the report—up to 4 fields for a portrait report and up to 6 fields for a landscape report (required).
LocatorReportParameters
  fieldNames : Array
Fields of the BusinessPoints layer to be exported to the report—up to 4 fields for a portrait report and up to 6 fields for a landscape report (required).
LocatorReportParameters
  nearestDistance : Number
Nearest distance threshold.
LocatorReportParameters
  nearestDistanceUnits : String
Units the nearestDistance property value is measured in.
LocatorReportParameters
 InheritedoutputAnalysisItem : FolderItem
Configuration options for storing the output feature class in the repository.
AnalysisAndReportParameters
 InheritedoutputReportItem : FolderItem
Configuration options for storing the output report in the repository.
AnalysisAndReportParameters
 InheritedoutputSpatialReference : SpatialReference
The spatial reference to return the output feature set in.
AnalysisAndReportParameters
 InheritedoutputTypes : OutputTypes
Task output types.
BATaskParameters
 InheritedrenderingParameters : RenderingParameters
Configuration options for rendering output to map image.
AnalysisAndReportParameters
  reportOrientation : ReportOrientation
Orientation of the report.
LocatorReportParameters
 InheritedresultType : BAResultType
[read-only] Type of the result returned by the task associated with these parameters.
BATaskParameters
 InheritedreturnGeometry : Boolean
An option specifying the presence of the shape attribute in the returned record set.
AnalysisAndReportParameters
  singleStoreID : String
ID of a single store in the stores layer to generate report for.
LocatorReportParameters
 InheritedstandardReportOptions : ReportOptions
Standard report options.
StandardReportParameters
  storeIDField : String
The attribute field name in the input stores layer which is associated with unique store/business IDs (typically store numbers for retail establishments with multiple locations).
LocatorReportParameters
  storeNameField : String
The attribute field name in the input stores layer which is associated with store/business names.
LocatorReportParameters
  stores : PointLayer
A point layer containing point features such as businesses, hospitals, schools, etc., which represent the locations of your businesses (required).
LocatorReportParameters
 InheritedtaskName : String
[read-only] Name of a Community Analyst Task associated with these parameters.
BATaskParameters
Public Methods
 MethodDefined By
  
Creates a new instance of the LocatorReportParameters class.
LocatorReportParameters
Property Detail
analysisExtentproperty
analysisExtent:Geometry

Spatial/geographic extent to restrict analysis by. This parameter expects a value of the Extent or Polygon type.


Implementation
    public function get analysisExtent():Geometry
    public function set analysisExtent(value:Geometry):void

See also

businessesSearchMethodproperty 
businessesSearchMethod:BusinessesSearchMethod

Method to search for the closest competitors.

The default value is BusinessesSearchMethod.FIND_CLOSEST.


Implementation
    public function get businessesSearchMethod():BusinessesSearchMethod
    public function set businessesSearchMethod(value:BusinessesSearchMethod):void
businessPointsproperty 
businessPoints:PointLayer

Point layer with competitors' business points (requred).


Implementation
    public function get businessPoints():PointLayer
    public function set businessPoints(value:PointLayer):void
calculationMethodproperty 
calculationMethod:DistanceCalcType

Distance calculation method.

The default value is DistanceCalcType.STRAIGHT_LINE.


Implementation
    public function get calculationMethod():DistanceCalcType
    public function set calculationMethod(value:DistanceCalcType):void
closestBusinessesCountproperty 
closestBusinessesCount:int

Closest businesses count threshold. This value is used if the businessesSearchMethod property value is BusinessesSearchMethod.FIND_CLOSEST. Negative value means showing all businesses in the output report.

The default value is -1.


Implementation
    public function get closestBusinessesCount():int
    public function set closestBusinessesCount(value:int):void
distanceUnitsproperty 
distanceUnits:String

Units to report distances in. For drive time calculation method, this property is ignored and the distances in minutes are displayed in the report. This should be a string constant from the com.esri.ags.Units class.

The default value is Units.MILES.


Implementation
    public function get distanceUnits():String
    public function set distanceUnits(value:String):void
fieldAliasesproperty 
fieldAliases:Array

Aliases of fields to be shown in the report—up to 4 fields for a portrait report and up to 6 fields for a landscape report (required).


Implementation
    public function get fieldAliases():Array
    public function set fieldAliases(value:Array):void
fieldNamesproperty 
fieldNames:Array

Fields of the BusinessPoints layer to be exported to the report—up to 4 fields for a portrait report and up to 6 fields for a landscape report (required).


Implementation
    public function get fieldNames():Array
    public function set fieldNames(value:Array):void
nearestDistanceproperty 
nearestDistance:Number

Nearest distance threshold. This threshold is required if the businessesSearchMethod property value is BusinessesSearchMethod.WITHIN_RANGE.

The default value is NaN.


Implementation
    public function get nearestDistance():Number
    public function set nearestDistance(value:Number):void
nearestDistanceUnitsproperty 
nearestDistanceUnits:String

Units the nearestDistance property value is measured in. This value is used if the businessesSearchMethod property value is BusinessesSearchMethod.WITHIN_RANGE. This should be a string constant from the com.esri.ags.Units class.

The default value is Units.MILES.


Implementation
    public function get nearestDistanceUnits():String
    public function set nearestDistanceUnits(value:String):void
reportOrientationproperty 
reportOrientation:ReportOrientation

Orientation of the report. If this property value is null, the orientation is selected depending on the number of fields to be shown in the report—portrait orientation if the number of fields does not exceed 4 and landscape orientation otherwise.

The default value is null.


Implementation
    public function get reportOrientation():ReportOrientation
    public function set reportOrientation(value:ReportOrientation):void
singleStoreIDproperty 
singleStoreID:String

ID of a single store in the stores layer to generate report for.


Implementation
    public function get singleStoreID():String
    public function set singleStoreID(value:String):void
storeIDFieldproperty 
storeIDField:String

The attribute field name in the input stores layer which is associated with unique store/business IDs (typically store numbers for retail establishments with multiple locations).

The default value is "STORE_ID".


Implementation
    public function get storeIDField():String
    public function set storeIDField(value:String):void
storeNameFieldproperty 
storeNameField:String

The attribute field name in the input stores layer which is associated with store/business names.

The default value is "NAME".


Implementation
    public function get storeNameField():String
    public function set storeNameField(value:String):void
storesproperty 
stores:PointLayer

A point layer containing point features such as businesses, hospitals, schools, etc., which represent the locations of your businesses (required).


Implementation
    public function get stores():PointLayer
    public function set stores(value:PointLayer):void
Constructor Detail
LocatorReportParameters()Constructor
public function LocatorReportParameters(outputTypes:OutputTypes = null)

Creates a new instance of the LocatorReportParameters class.

Parameters
outputTypes:OutputTypes (default = null) — Task output types.
Examples
ActionScript to create LocatorReportParameters and then use in a Locator Report task:
                     
     var parameters : LocatorReportParameters = new LocatorReportParameters();
     
     // The PointLayer type could take either data as type
     // com.esri.ags.tasks.FeatureSet, com.esri.baserver.FolderItem,
     // or an array of com.esri.bacore.PointRecord items, e.g.
     //var points:Array = [new PointRecord("store_1", "Store 1", "1", 34.052074, -117.207841)];
     
     // Set stores as an array of PointRecord items.
     parameters.stores = new PointLayer(points);
     
     // Set businessPoints with a valid data type. 
      parameters.businessPoints = new PointLayer(businessPoints);
     
     // Set fields of the businessPoints layer to be exported to the report.
     parameters.fieldNames = ["NAME", "DESCR"];
     
     // Set aliases of fields to be shown in the report.
     parameters.fieldAliases = ["Name", "Description"];
     
     // Set report parameters. 
     parameters.standardReportOptions = new ReportOptions("PDF");
     
     locatorReportTask.execute(parameters, new Responder(resultHandler, faultHandler));