BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bdlt::Timetable_CompactableTransition Class Reference

#include <bdlt_timetable.h>

Public Types

enum  { k_UNSET_TRANSITION_CODE }
 

Public Member Functions

 Timetable_CompactableTransition ()
 
 Timetable_CompactableTransition (const Time &time, int code)
 
 Timetable_CompactableTransition (const Timetable_CompactableTransition &original)
 
 ~Timetable_CompactableTransition ()=default
 
Timetable_CompactableTransitionoperator= (const Timetable_CompactableTransition &rhs)
 
const Timetime () const
 Return the time of this compactable transition.
 
int code () const
 Return the code of this compactable transition.
 
bsl::ostream & print (bsl::ostream &stream, int level=0, int spacesPerLevel=4) const
 

Friends

class Timetable
 
class Timetable_Day
 

Detailed Description

This simply-constrained attribute class represents a state transition, implemented as a time for when the transition occurs, and a code to indicate the new state.

See bdlt_timetable

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
k_UNSET_TRANSITION_CODE 

Constructor & Destructor Documentation

◆ Timetable_CompactableTransition() [1/3]

bdlt::Timetable_CompactableTransition::Timetable_CompactableTransition ( )
inline

Create a Timetable_CompactableTransition having time value Time(0) and code k_UNSET_TRANSITION_CODE.

◆ Timetable_CompactableTransition() [2/3]

bdlt::Timetable_CompactableTransition::Timetable_CompactableTransition ( const Time time,
int  code 
)
inline

Create a Timetable_CompactableTransition having the specified time and code. The behavior is undefined unless 24 > time.hour() and 0 <= code || k_UNSET_TRANSITION_CODE == code.

◆ Timetable_CompactableTransition() [3/3]

bdlt::Timetable_CompactableTransition::Timetable_CompactableTransition ( const Timetable_CompactableTransition original)
inline

Create a Timetable_CompactableTransition having the same value as the specified original object.

◆ ~Timetable_CompactableTransition()

bdlt::Timetable_CompactableTransition::~Timetable_CompactableTransition ( )
default

Member Function Documentation

◆ code()

int bdlt::Timetable_CompactableTransition::code ( ) const
inline

◆ operator=()

Timetable_CompactableTransition & bdlt::Timetable_CompactableTransition::operator= ( const Timetable_CompactableTransition rhs)
inline

Assign to this object the value of the specified rhs compactable transition, and return a reference providing modifiable access to this object.

◆ print()

bsl::ostream & bdlt::Timetable_CompactableTransition::print ( bsl::ostream &  stream,
int  level = 0,
int  spacesPerLevel = 4 
) const

Format this object to the specified output stream at the (absolute value of) the optionally specified indentation level and return a reference to the modifiable stream. If level is specified, optionally specify spacesPerLevel, the number of spaces per indentation level for this and all of its nested objects. If level is negative, suppress indentation of the first line. If spacesPerLevel is negative, format the entire output on one line, suppressing all but the initial indentation (as governed by level). If stream is not valid on entry, this operation has no effect.

◆ time()

const Time & bdlt::Timetable_CompactableTransition::time ( ) const
inline

Friends And Related Symbol Documentation

◆ Timetable

friend class Timetable
friend

◆ Timetable_Day

friend class Timetable_Day
friend

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