|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.nrao.sss.model.resource.SimpleReceiverSelector
public class SimpleReceiverSelector
A very simple receiver selector.
This selector merely looks for overlaps between the frequency range of the specifications and the frequency ranges of the available receivers.
Version Info:
$Revision: 2294 $ |
$Date: 2009-05-11 15:11:56 -0600 (Mon, 11 May 2009) $ |
$Author: dharland $ |
Constructor Summary | |
---|---|
SimpleReceiverSelector()
Creates a new instance. |
|
SimpleReceiverSelector(ReceiverProvider provider)
Creates a new instance that uses provider as a source of
receivers. |
Method Summary | |
---|---|
ReceiverBand |
selectBestReceiverFor(FrequencyRange targetRange)
Returns the best receiver to use for the given range of sky frequencies. |
List<ReceiverSelection> |
selectReceivers(FrequencyRange targetRange)
Selects best combination of receivers to cover given frequency range. |
List<ReceiverSelection> |
selectReceivers(FrequencySpectrum targetSpectrum)
Selects best combination of receivers to cover given frequency spectrum. |
List<ReceiverSelection> |
selectReceivers(ObservingMode mode,
ResourceSpecification specs)
Returns a list of one or more selections that satisfy the given portion of the given specs. |
List<ReceiverSelection> |
selectReceivers(PulsarSpecification specs)
Returns a list of one or more selections that satisfy the given specs. |
List<ReceiverSelection> |
selectReceivers(ResourceSpecification specs)
Returns a list of one or more selections that satisfy the given specs. |
List<ReceiverSelection> |
selectReceivers(SkyFrequencySpecification specs)
Returns a list of one or more selections that satisfy the given specs. |
List<ReceiverSelection> |
selectReceivers(SpectralLineSpecification specs)
Returns a list of one or more selections that satisfy the given specs. |
void |
setProvider(ReceiverProvider provider)
Sets the universe of receivers from which selections will be made. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleReceiverSelector(ReceiverProvider provider)
provider
as a source of
receivers.
provider
- the receiver container for this selector.public SimpleReceiverSelector()
Method Detail |
---|
public List<ReceiverSelection> selectReceivers(FrequencyRange targetRange)
targetRange
- the frequency range for which receiver coverage
is desired.
public ReceiverBand selectBestReceiverFor(FrequencyRange targetRange)
ReceiverSelector
This method returns a single receiver, even if multiple receivers cover the target range. If one receiver covers more of the target range than the others, it is the receiver returned. If multiple receivers cover the range equally well, the receiver returned is up to the implementing class. If no receiver overlaps the target range, the receiver that has the smallest distance between itself and the target range is returned. Note that this means the returned receiver may not be useful for the target it range at all, but is merely the best of the not-so-useful receivers.
This method may return null if any one or more of the following is true:
targetRange
- a sky frequency range for which the best receiver is sought.
public List<ReceiverSelection> selectReceivers(FrequencySpectrum targetSpectrum)
targetSpectrum
- the frequency spectrum for which receiver coverage
is desired.
public void setProvider(ReceiverProvider provider)
ReceiverSelector
setProvider
in interface ReceiverSelector
provider
- a provider of receivers.public List<ReceiverSelection> selectReceivers(ResourceSpecification specs)
ReceiverSelector
specs
.
selectReceivers
in interface ReceiverSelector
specs
- a resource specification, expressed in terms of science,
as opposed to instrumentation.
public List<ReceiverSelection> selectReceivers(ObservingMode mode, ResourceSpecification specs)
ReceiverSelector
specs
.
The mode
parameter is used to ignore the portions of
specs
that are of different modes. For example, calling
mySelector.selectReceivers(ObservingMode.SPECTRAL_LINE, mySpecs)
will cause this selector to consider only the spectral line specifications.
Note that this is a little different than calling
mySelector.selectReceivers(mySpecs.getSpectralLineSpecs().get(i))
because all the spectral line specifications in specs
will
be considered by this method.
selectReceivers
in interface ReceiverSelector
mode
- the portion of specs
to which this method will
limit its attention.specs
- a resource specification, expressed in terms of science,
as opposed to instrumentation.
public List<ReceiverSelection> selectReceivers(SkyFrequencySpecification specs)
ReceiverSelector
specs
.
selectReceivers
in interface ReceiverSelector
specs
- a resource specification, expressed in terms of science,
as opposed to instrumentation.
public List<ReceiverSelection> selectReceivers(SpectralLineSpecification specs)
ReceiverSelector
specs
.
selectReceivers
in interface ReceiverSelector
specs
- a resource specification, expressed in terms of science,
as opposed to instrumentation.
public List<ReceiverSelection> selectReceivers(PulsarSpecification specs)
ReceiverSelector
specs
.
selectReceivers
in interface ReceiverSelector
specs
- a resource specification, expressed in terms of science,
as opposed to instrumentation.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |