Package gov.usgs.earthquake.dyfi
Class DYFIIndexerModule
- java.lang.Object
-
- gov.usgs.util.DefaultConfigurable
-
- gov.usgs.earthquake.indexer.DefaultIndexerModule
-
- gov.usgs.earthquake.dyfi.DYFIIndexerModule
-
- All Implemented Interfaces:
IndexerModule
,Configurable
public class DYFIIndexerModule extends DefaultIndexerModule
DYFI Indexer Module. UsesDYFIProduct
class to summarize product.
-
-
Field Summary
-
Fields inherited from class gov.usgs.earthquake.indexer.DefaultIndexerModule
ANSS_CONTRIBUTOR_WEIGHT, AUTHORITATIVE_EVENT_WEIGHT, AUTHORITATIVE_WEIGHT, DEFAULT_PREFERRED_WEIGHT, IGNORE_REGIONS_PROPERTY, NEIC_CONTRIBUTOR_WEIGHT, SAME_SOURCE_WEIGHT
-
Fields inherited from interface gov.usgs.earthquake.indexer.IndexerModule
LEVEL_DEFAULT, LEVEL_SUPPORTED, LEVEL_UNSUPPORTED
-
-
Constructor Summary
Constructors Constructor Description DYFIIndexerModule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ProductSummary
getProductSummary(Product product)
Create a ProductSummary from a Product.int
getSupportLevel(Product product)
This module provides a default level of support for any type of product.-
Methods inherited from class gov.usgs.earthquake.indexer.DefaultIndexerModule
configure, getBaseProductType, getIgnoreRegions, getPreferredWeight, getSignatureVerifier, setSignatureVerifier
-
Methods inherited from class gov.usgs.util.DefaultConfigurable
getName, setName, shutdown, startup
-
-
-
-
Method Detail
-
getSupportLevel
public int getSupportLevel(Product product)
Description copied from class:DefaultIndexerModule
This module provides a default level of support for any type of product.- Specified by:
getSupportLevel
in interfaceIndexerModule
- Overrides:
getSupportLevel
in classDefaultIndexerModule
- Parameters:
product
- the product to test.- Returns:
- IndexerModule.LEVEL_DEFAULT.
-
getProductSummary
public ProductSummary getProductSummary(Product product) throws java.lang.Exception
Description copied from class:DefaultIndexerModule
Create a ProductSummary from a Product. Uses the ProductSummary(Product) constructor, which copies product information. Checks whether product is within its authoritative region, and if so boosts preferredWeight by AUTHORITATIVE_WEIGHT.- Specified by:
getProductSummary
in interfaceIndexerModule
- Overrides:
getProductSummary
in classDefaultIndexerModule
- Parameters:
product
- the product to summarize.- Returns:
- ProductSummary for Product object.
- Throws:
java.lang.Exception
- if error occurs
-
-