Marsyas  0.5.0-beta1
Public Member Functions
Repeat Class Reference

encapsulates repetition information for scheduled events More...

#include <Repeat.h>

Public Member Functions

mrs_natural getCount ()
std::string getInterval ()
mrs_natural interval2samples (mrs_real srate)
 convert the repeat interval to a sample count based on the given sample rate
bool isInfinite ()
void operator++ ()
void operator++ (int)
void operator-- ()
void operator-- (int)
 Repeat ()
 specify no repetition
 Repeat (std::string time_interval)
 specify infinite repetition
 Repeat (std::string time_interval, mrs_natural rep_count)
 specify finite repetition
virtual bool repeat ()
 report whether this Repeat specifies another repeat
void set (bool inf, std::string time_interval, mrs_natural rep_count)
 specify finite repetition
void setCount (mrs_natural count)
void setInfinite (bool inf)
void setInterval (std::string interval)
virtual ~Repeat ()

Detailed Description

encapsulates repetition information for scheduled events

Author:
Neil Burroughs inb@cs.uvic.ca

Definition at line 36 of file Repeat.h.


Constructor & Destructor Documentation

Repeat ( )

specify no repetition

Definition at line 25 of file Repeat.cpp.

Repeat ( std::string  time_interval)

specify infinite repetition

Parameters:
time_intervalthe interval of time between repetitions

Definition at line 30 of file Repeat.cpp.

Repeat ( std::string  time_interval,
mrs_natural  rep_count 
)

specify finite repetition

Parameters:
time_intervalthe interval of time between repetitions
rep_countthe number of times to repeat

Definition at line 35 of file Repeat.cpp.

~Repeat ( ) [virtual]

Definition at line 46 of file Repeat.cpp.


Member Function Documentation

mrs_natural getCount ( ) [inline]

Definition at line 77 of file Repeat.h.

std::string getInterval ( ) [inline]

Definition at line 78 of file Repeat.h.

mrs_natural interval2samples ( mrs_real  srate)

convert the repeat interval to a sample count based on the given sample rate

Parameters:
sratethe sample rate to be used in the conversion
Returns:
the count of samples

Definition at line 57 of file Repeat.cpp.

bool isInfinite ( ) [inline]

Definition at line 76 of file Repeat.h.

void operator++ ( ) [inline]

Definition at line 84 of file Repeat.h.

void operator++ ( int  ) [inline]

Definition at line 85 of file Repeat.h.

void operator-- ( ) [inline]

Definition at line 86 of file Repeat.h.

void operator-- ( int  ) [inline]

Definition at line 87 of file Repeat.h.

bool repeat ( ) [virtual]

report whether this Repeat specifies another repeat

Returns:
true if repeat is warranted

Definition at line 41 of file Repeat.cpp.

void set ( bool  inf,
std::string  time_interval,
mrs_natural  rep_count 
)

specify finite repetition

Parameters:
inftrue if repeat is to be infinite which negates rep_count
time_intervalthe interval of time between repetitions
rep_countthe number of times to repeat

Definition at line 49 of file Repeat.cpp.

void setCount ( mrs_natural  count) [inline]

Definition at line 81 of file Repeat.h.

void setInfinite ( bool  inf) [inline]

Definition at line 80 of file Repeat.h.

void setInterval ( std::string  interval) [inline]

Definition at line 82 of file Repeat.h.


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