opm-common
Loading...
Searching...
No Matches
Opm::GroupSatelliteInjection Class Reference

Group level satellite production. More...

#include <GroupSatelliteInjection.hpp>

Classes

class  Rate
 Satellite injection rates for a single phase. More...
 

Public Types

using RateIx = std::vector< Rate >::size_type
 Index type for looking up phase rate objects.
 

Public Member Functions

 GroupSatelliteInjection ()=default
 Default constructor.
 
 GroupSatelliteInjection (const std::string &group)
 Constructor.
 
Raterate (const Phase phase)
 Read/write access to injection rate object for particular phase.
 
const std::string & name () const
 Group name.
 
std::optional< RateIxrateIndex (const Phase phase) const
 Compute lookup index for particular phase.
 
const Rateoperator[] (const RateIx i) const
 Read only satellite injection rates.
 
bool operator== (const GroupSatelliteInjection &that) const
 Equality predicate.
 
template<class Serializer >
void serializeOp (Serializer &serializer)
 Convert between byte array and object representation.
 

Static Public Member Functions

static GroupSatelliteInjection serializationTestObject ()
 Create a serialisation test object.
 

Detailed Description

Group level satellite production.

Constructor & Destructor Documentation

◆ GroupSatelliteInjection() [1/2]

Opm::GroupSatelliteInjection::GroupSatelliteInjection ( )
default

Default constructor.

Forms an object that's mostly suitable as a target in a deserialisation operation.

◆ GroupSatelliteInjection() [2/2]

Opm::GroupSatelliteInjection::GroupSatelliteInjection ( const std::string &  group)
explicit

Constructor.

Creates a container for a particular named group, but without any satellite injection rates defined for any phase.

Parameters
[in]groupGroup name.

Member Function Documentation

◆ name()

const std::string & Opm::GroupSatelliteInjection::name ( ) const
inline

Group name.

This is needed to meet interface requirements of class ScheduleState::map_member<>, but is otherwise redundant.

◆ operator==()

bool Opm::GroupSatelliteInjection::operator== ( const GroupSatelliteInjection that) const

Equality predicate.

Parameters
[in]thatObject against which
*this
will be tested for equality.
Returns
Whether or not
*this
is the same as that.

◆ operator[]()

const Rate & Opm::GroupSatelliteInjection::operator[] ( const RateIx  i) const
inline

Read only satellite injection rates.

Parameters
[in]iLookup index. Typically computed in a previous call to member function rateIndex().
Returns
Satellite injection rate object at position i.

◆ rate()

Opm::GroupSatelliteInjection::Rate & Opm::GroupSatelliteInjection::rate ( const Phase  phase)

Read/write access to injection rate object for particular phase.

Will create a Rate object as needed.

Parameters
[in]phaseInjection phase.
Returns
Mutable Rate object corresponding to injection phase phase.

◆ rateIndex()

std::optional< Opm::GroupSatelliteInjection::RateIx > Opm::GroupSatelliteInjection::rateIndex ( const Phase  phase) const

Compute lookup index for particular phase.

Parameters
[in]phaseInjection phase.
Returns
Lookup index for injection phase phase. Nullopt if there are no satellite injection rates recorded for phase phase in this group.

◆ serializeOp()

template<class Serializer >
void Opm::GroupSatelliteInjection::serializeOp ( Serializer serializer)
inline

Convert between byte array and object representation.

Template Parameters
SerializerByte array conversion protocol.
Parameters
[in,out]serializerByte array conversion object.

The documentation for this class was generated from the following files: