Package gov.usgs.earthquake.nshmp.model
Class GriddedRuptureSet
- java.lang.Object
-
- gov.usgs.earthquake.nshmp.model.GriddedRuptureSet
-
- All Implemented Interfaces:
RuptureSet,Iterable<GridSource>
- Direct Known Subclasses:
GridRuptureSet
public abstract class GriddedRuptureSet extends Object implements Iterable<GridSource>
Base implementation for gridded rupture sets. Although most implementations in USGS NSHMs to date are uniformely spaced in latitude and longitude, this class makes no requirement that they be.- Author:
- U.S. Geological Survey
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract GridSourcegetNode(int index)Get the grid source at the specified node.GmmTreegmmTree()Return the ground motion model logic tree associated with this Rupture Set.intid()The numeric ID of this rupture set.Iterator<GridSource>iterator()abstract List<Location>locations()The list of grid node locations in this rupture set.Stringname()The display name of the rupture set.TectonicSettingsetting()TheTectonicSettingof this rupture set.Iterable<GridSource>siteIterable(Location site)Returns an iterable over the grid sources within the cuttoff distance from asite.Iterable<GridSource>siteIterable(Location site, double distance)Returns an iterable over the grid sources within the specifieddistancefrom asite.intsize()The number of grid nodes in this rupture set.StringtoString()SourceTypetype()TheSourceTypeidentifier.doubleweight()The weight of theSourceTreebranch to which this rupture set is attached.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Methods inherited from interface gov.usgs.earthquake.nshmp.model.RuptureSet
features, location, mfdTree, totalMfd
-
-
-
-
Method Detail
-
size
public int size()
The number of grid nodes in this rupture set.- Specified by:
sizein interfaceRuptureSet
-
locations
public abstract List<Location> locations()
The list of grid node locations in this rupture set.
-
getNode
public abstract GridSource getNode(int index)
Get the grid source at the specified node.- Parameters:
index- of the node to retrieve
-
iterator
public Iterator<GridSource> iterator()
- Specified by:
iteratorin interfaceIterable<GridSource>
-
siteIterable
public Iterable<GridSource> siteIterable(Location site)
Returns an iterable over the grid sources within the cuttoff distance from asite. The cutoff distance is derived from theGroundMotionModels associated with this rupture set.- Parameters:
site- of interest- See Also:
RuptureSet.gmmTree()
-
siteIterable
public Iterable<GridSource> siteIterable(Location site, double distance)
Returns an iterable over the grid sources within the specifieddistancefrom asite.- Parameters:
site- of interestdistance- from the site within which grid sources are returned by this iterator
-
name
public String name()
Description copied from interface:RuptureSetThe display name of the rupture set.- Specified by:
namein interfaceRuptureSet
-
id
public int id()
Description copied from interface:RuptureSetThe numeric ID of this rupture set.- Specified by:
idin interfaceRuptureSet
-
setting
public TectonicSetting setting()
Description copied from interface:RuptureSetTheTectonicSettingof this rupture set.- Specified by:
settingin interfaceRuptureSet
-
type
public SourceType type()
Description copied from interface:RuptureSetTheSourceTypeidentifier.- Specified by:
typein interfaceRuptureSet
-
gmmTree
public GmmTree gmmTree()
Description copied from interface:RuptureSetReturn the ground motion model logic tree associated with this Rupture Set.- Specified by:
gmmTreein interfaceRuptureSet
-
weight
public double weight()
Description copied from interface:RuptureSetThe weight of theSourceTreebranch to which this rupture set is attached.- Specified by:
weightin interfaceRuptureSet
-
-