Regina 7.3 Calculation Engine
Public Member Functions | Friends | List of all members
regina::SatBlockSpec Class Reference

Describes how a single saturated block forms a part of a larger saturated region. More...

#include <subcomplex/satregion.h>

Inheritance diagram for regina::SatBlockSpec:
regina::ShortOutput< SatBlockSpec > regina::Output< SatBlockSpec, false >

Public Member Functions

 SatBlockSpec (SatBlockSpec &&src) noexcept
 Moves the contents of the given structure into this new structure. More...
 
 ~SatBlockSpec ()
 Destroys this structure, along with the SatBlock that it holds. More...
 
SatBlockSpecoperator= (SatBlockSpec &&src) noexcept
 Moves the contents of the given structure into this structure. More...
 
void swap (SatBlockSpec &other) noexcept
 Swaps the contents of this and the given structure. More...
 
bool operator== (const SatBlockSpec &other) const
 Determines whether this and the given structure contain combinatorially equivalent information. More...
 
bool operator!= (const SatBlockSpec &other) const
 Determines whether this and the given structure do not contain combinatorially equivalent information. More...
 
const SatBlockblock () const
 Returns the full combinatorial structure of the saturated block. More...
 
bool refVert () const
 Returns whether the block is reflected vertically within the larger region. More...
 
bool refHoriz () const
 Returns whether the block is reflected horizontally within the larger region. More...
 
void writeTextShort (std::ostream &out) const
 Writes a short text representation of this object to the given output stream. More...
 
 SatBlockSpec (const SatBlockSpec &)=delete
 
SatBlockSpecoperator= (const SatBlockSpec &)=delete
 
void writeTextLong (std::ostream &out) const
 A default implementation for detailed output. More...
 
std::string str () const
 Returns a short text representation of this object. More...
 
std::string utf8 () const
 Returns a short text representation of this object using unicode characters. More...
 
std::string detail () const
 Returns a detailed text representation of this object. More...
 

Friends

class SatRegion
 

Detailed Description

Describes how a single saturated block forms a part of a larger saturated region.

A saturated region consists of several saturated blocks joined together along their boundary annuli. This is a helper class containing a single saturated block along with details of its orientation within a larger region.

The ring of saturated annuli around the boundary of the block gives a natural orientation to the block within the context of the base orbifold, just as the ring of edges around a polygon would give a natural orientation to that polygon within the context of a surrounding surface. Again drawing an analogy with the orientation of polygons within a surface, each block can be considered to have a correct or reflected orientation according to whether this ring of annuli runs clockwise or anticlockwise in the base orbifold.

The precise orientation of a block is described using two booleans. A block may be reflected horizontally, which preserves the directions of Seifert fibres but which reverses the clockwise/anticlockwise orientation as discussed above. A block may also be reflected vertically, which preserves the clockwise/anticlockwise orientation but which reverses the directions of the Seifert fibres. A block may of course be reflected both horizontally and vertically, or it may not be reflected at all.

Since Regina 7.0, this helper structure now owns its internal SatBlock, and will destroy this SatBlock when this structure itself is destroyed. This is a change in behaviour from Regina 6.0.1 and earlier.

Because of these new ownership semantics, SatBlockSpec is no longer copyable. However, it is both movable and swappable (it implements C++ moves semantics and adheres to the C++ Swappable requirement).

Constructor & Destructor Documentation

◆ SatBlockSpec()

regina::SatBlockSpec::SatBlockSpec ( SatBlockSpec &&  src)
inlinenoexcept

Moves the contents of the given structure into this new structure.

The internal SatBlock pointer will be preserved; that is, the pointer this->block() after the move will be the same as the pointer src.block() before the move.

The structure that was passed (src) will no longer be usable.

◆ ~SatBlockSpec()

regina::SatBlockSpec::~SatBlockSpec ( )
inline

Destroys this structure, along with the SatBlock that it holds.

Member Function Documentation

◆ block()

const SatBlock * regina::SatBlockSpec::block ( ) const
inline

Returns the full combinatorial structure of the saturated block.

Returns
the saturated block structure.

◆ detail()

std::string regina::Output< SatBlockSpec , supportsUtf8 >::detail ( ) const
inherited

Returns a detailed text representation of this object.

This text may span many lines, and should provide the user with all the information they could want. It should be human-readable, should not contain extremely long lines (which cause problems for users reading the output in a terminal), and should end with a final newline. There are no restrictions on the underlying character set.

Returns
a detailed text representation of this object.

◆ operator!=()

bool regina::SatBlockSpec::operator!= ( const SatBlockSpec other) const
inline

Determines whether this and the given structure do not contain combinatorially equivalent information.

Specifically, to compare as equal, two SatBlockSpec objects must hold blocks of the same type with the same combinatorial parameters (as tested by the SatBlock equality comparison), and they must use the same horizontal/vertical reflection parameters within the larger region (as returned by refVert() and refHoriz()).

Parameters
otherthe structure to compare against this.
Returns
true if and only if this and other do not contain combinatorially equivalent information.

◆ operator=()

SatBlockSpec & regina::SatBlockSpec::operator= ( SatBlockSpec &&  src)
inlinenoexcept

Moves the contents of the given structure into this structure.

The structure that was passed (src) will no longer be usable.

The internal SatBlock pointer will be preserved; that is, the pointer this->block() after the move will be the same as the pointer src.block() before the move.

Returns
a reference to this structure.

◆ operator==()

bool regina::SatBlockSpec::operator== ( const SatBlockSpec other) const
inline

Determines whether this and the given structure contain combinatorially equivalent information.

Specifically, to compare as equal, two SatBlockSpec objects must hold blocks of the same type with the same combinatorial parameters (as tested by the SatBlock equality comparison), and they must use the same horizontal/vertical reflection parameters within the larger region (as returned by refVert() and refHoriz()).

Parameters
otherthe structure to compare against this.
Returns
true if and only if this and other contain combinatorially equivalent information.

◆ refHoriz()

bool regina::SatBlockSpec::refHoriz ( ) const
inline

Returns whether the block is reflected horizontally within the larger region.

See the class notes for details.

Returns
true if and only if the block is reflected horizontally.

◆ refVert()

bool regina::SatBlockSpec::refVert ( ) const
inline

Returns whether the block is reflected vertically within the larger region.

See the class notes for details.

Returns
true if and only if the block is reflected vertically.

◆ str()

std::string regina::Output< SatBlockSpec , supportsUtf8 >::str ( ) const
inherited

Returns a short text representation of this object.

This text should be human-readable, should use plain ASCII characters where possible, and should not contain any newlines.

Within these limits, this short text ouptut should be as information-rich as possible, since in most cases this forms the basis for the Python __str__() and __repr__() functions.

Python
The Python "stringification" function __str__() will use precisely this function, and for most classes the Python __repr__() function will incorporate this into its output.
Returns
a short text representation of this object.

◆ swap()

void regina::SatBlockSpec::swap ( SatBlockSpec other)
inlinenoexcept

Swaps the contents of this and the given structure.

In particular, the internal SatBlock pointers will be swapped; that is, the pointers this->block() and other.block() after the move will be the same as other.block() and this->block() were respectively before the move.

Parameters
otherthe structure whose contents should be swapped with this.

◆ utf8()

std::string regina::Output< SatBlockSpec , supportsUtf8 >::utf8 ( ) const
inherited

Returns a short text representation of this object using unicode characters.

Like str(), this text should be human-readable, should not contain any newlines, and (within these constraints) should be as information-rich as is reasonable.

Unlike str(), this function may use unicode characters to make the output more pleasant to read. The string that is returned will be encoded in UTF-8.

Returns
a short text representation of this object.

◆ writeTextLong()

void regina::ShortOutput< SatBlockSpec , false >::writeTextLong ( std::ostream &  out) const
inlineinherited

A default implementation for detailed output.

This routine simply calls T::writeTextShort() and appends a final newline.

Python
Not present. Instead you can call detail() from the subclass T, which returns this output as a string.
Parameters
outthe output stream to which to write.

◆ writeTextShort()

void regina::SatBlockSpec::writeTextShort ( std::ostream &  out) const

Writes a short text representation of this object to the given output stream.

Python
Not present. Use str() instead.
Parameters
outthe output stream to which to write.

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

Copyright © 1999-2023, The Regina development team
This software is released under the GNU General Public License, with some additional permissions; see the source code for details.
For further information, or to submit a bug or other problem, please contact Ben Burton (bab@maths.uq.edu.au).