# PhasicFlow: multiTriSurface Class Reference
PhasicFlow is an open-source parallel DEM (discrete element method) package for simulating granular flow. It is developed in C++ and can be exectued on both GPU (like CUDA) and CPU.

multiTriSurface Class Reference
Inheritance diagram for multiTriSurface:
[legend]
Collaboration diagram for multiTriSurface:
[legend]

## Public Member Functions

| TypeInfo ("multiTriSurface")
| multiTriSurface (const objectFile &obj, repository *owner)
| Construct from objectFile and owner repository. More...
| multiTriSurface (const objectFile &objf, repository *owner, const multiTriSurface &surf)
| Construct from another multiTriSurface. More...
| multiTriSurface (const multiTriSurface &)=default
| Copy construct (default) More...
multiTriSurface & | operator= (const multiTriSurface &)=default
| Copy assignment (default) More...
| multiTriSurface (multiTriSurface &&)=delete
| No move construct. More...
multiTriSurface & | operator= (multiTriSurface &&)=delete
| No move assignment. More...
| ~multiTriSurface () override=default
| default destructor More...
bool | appendSurface (const word &name, const realx3x3Vector &vertices)
uint32 | numSurfaces () const
const subSurfaceList & | subSurfaces () const
rangeU32 | subSurfaceRange (uint32 nSub) const
rangeU32 | subSurfacePointRange (uint32 nSub) const
void | clear ()
| Clear the content of object. More...
uint32 | subSurfaceSize (uint32 nSub) const
uint32 | subSurfaceNumPoints (uint32 nSub) const
word | subSurfaceName (uint32 nSub) const
bool | read (iIstream &is, const IOPattern &iop) override
bool | write (iOstream &os, const IOPattern &iop) const override
Public Member Functions inherited from triSurface
| TypeInfo ("triSurface")
| triSurface (const objectFile &objf, repository *owner, const triSurface &surf)
| triSurface (const realx3x3Field_H &triangles, repository *owner=nullptr)
| ~triSurface () override=default
uint32 | numPoints () const
uint32 | size () const
uint32 | capacity () const
const realx3Field_D & | points () const
realx3Field_D & | points ()
const auto & | area () const
auto & | area ()
const uint32x3Field_D & | vertices () const
uint32x3Field_D & | vertices ()
auto & | normals ()
const auto & | normals () const
void | clear ()
auto | getTriangleAccessor () const
| Obtain an object for accessing triangles. More...
bool | read (iIstream &is, const IOPattern &iop) override
bool | write (iOstream &os, const IOPattern &iop) const override
Public Member Functions inherited from IOobject
virtual word | typeName () const =0
| IOobject (const objectFile &objf, const IOPattern &iop, repository *owner)
| ~IOobject () override
| IOobject (const IOobject &src)=delete
| IOobject (IOobject &&src)=delete
const IOPattern & | ioPattern () const
const repository * | owner () const override
repository * | owner ()
repository * | releaseOwner (bool fromOwner=false)
bool | isIncluded (const word &objName) const override
bool | isExcluded (const word &objName) const override
bool | readObject (bool rdHdr=true)
bool | writeObject () const
bool | readObject (iIstream &is, bool rdHdr=true)
bool | writeObject (iOstream &os) const
Public Member Functions inherited from IOfileHeader
| IOfileHeader (const objectFile &objf)
const word & | objectName () const
const word & | objectType () const
fileSystem | path () const
bool | outFileBinary () const
bool | inFileBinary () const
bool | headerOk (bool silent=false)
bool | implyRead () const
| Imply read. More...
bool | implyWrite () const
| Imply write. More...
bool | fileExist () const
| Check if file exists. More...
bool | readIfPresent () const
| Check read if present. More...
bool | writeHeader () const
| Check if the header should be written to file True: on master + implyWrite + readWriteHeader = true False: otherwise. More...
bool | writeHeader (iOstream &os, const word &typeName, bool forceWrite=false) const
| Write the header to the file , typeName comes from caller. More...
bool | writeHeader (iOstream &os, bool forceWrite=false) const
| Write the header to the file, typeName comes from the one read from file. More...
bool | readHeader () const
| Check if header should be read from file. More...
bool | readHeader (iIstream &is, bool silent=false)
| Read the header in the file. More...
bool | writeBanner (iOstream &os) const
| write the banner More...
bool | writeSeparator (iOstream &os) const
| wirte a separator line More...
Public Member Functions inherited from objectFile
| objectFile (const word &name)
| objectFile (const word &name, const fileSystem &localPath, const readFlag &rf=readFlag::READ_NEVER, const writeFlag &wf=writeFlag::WRITE_NEVER, bool rwHeader=true)
| objectFile (const objectFile &src)=default
| objectFile (objectFile &&src)=default
objectFile & | operator= (const objectFile &rhs)=default
objectFile & | operator= (objectFile &&rhs)=default
virtual | ~objectFile ()=default
virtual const word & | name () const
virtual const fileSystem & | localPath () const
readFlag | rFlag () const
writeFlag | wFlag () const
bool | isReadAlways () const
bool | isReadNever () const
bool | isReadIfPresent () const
bool | isWriteAlways () const
bool | isWriteNever () const
bool | readWriteHeader () const
Public Member Functions inherited from subscriber
| subscriber (const word &name)
| subscriber (const subscriber &)
| Copy constructor, only copies the name, not the list. More...
| subscriber (subscriber &&)
| Move constructor, moves the name and the list, also change the subriber of the object in the list More...
subscriber & | operator= (const subscriber &)
| Copy assignemnt, only assign the name, do not assign the list. More...
subscriber & | operator= (subscriber &&)
| Move assignment, move assign name and list, also change the subcriber of the object in the list More...
virtual | ~subscriber ()
virtual bool | subscribe (message msg, observer *obsevr) const
virtual bool | unsubscribe (observer *obsevr) const
bool | notify (uint32 iter, real t, real dt, const message msg, const anyList &varList)
bool | notify (const timeInfo &ti, const message msg, const anyList &varList)
const word & | subscriberName () const

## Private Attributes

subSurfaceList | subSurfaces_

## Additional Inherited Members

Public Types inherited from objectFile
enum | readFlag { READ_ALWAYS, READ_NEVER, READ_IF_PRESENT }
enum | writeFlag { WRITE_ALWAYS, WRITE_NEVER }
Protected Member Functions inherited from triSurface
bool | calculateNormals ()
bool | calculateArea ()
bool | append (const realx3x3Field_H &triangles)
bool | append (const realx3x3Vector &triangles)
| triSurface (const objectFile &obj, repository *owner)
Protected Member Functions inherited from IOfileHeader
uniquePtr< iFstream > | inStream () const
uniquePtr< oFstream > | outStream () const
uniquePtr< oFstream > | dummyOutStream () const
Protected Attributes inherited from IOfileHeader
word | objectName_
word | objectType_
word | fileFormat_ = "ASCII"
| file format read from file More...

## Detailed Description

Definition at line 32 of file multiTriSurface.hpp.

## Constructor & Destructor Documentation

## multiTriSurface() [1/4]

multiTriSurface | ( | const objectFile & | obj,
|  | repository * | owner
| ) |  |

Construct from objectFile and owner repository.

This is mainly used for reading from file.

Parameters

  obj | object file
  owner | owner repository

Definition at line 25 of file multiTriSurface.cpp.

References pFlow::endl(), fatalErrorInFunction, and fatalExit.

Here is the call graph for this function:

## multiTriSurface() [2/4]

multiTriSurface | ( | const objectFile & | objf,
|  | repository * | owner,
|  | const multiTriSurface & | surf
| ) |  |

Construct from another multiTriSurface.

Definition at line 42 of file multiTriSurface.cpp.

## multiTriSurface() [3/4]

multiTriSurface | ( | const multiTriSurface & |  | ) |

default

Copy construct (default)

## multiTriSurface() [4/4]

multiTriSurface | ( | multiTriSurface && |  | ) |

delete

No move construct.

## ~multiTriSurface()

~multiTriSurface | ( |  | ) |

overridedefault

default destructor

## Member Function Documentation

## TypeInfo()

TypeInfo | ( | "multiTriSurface" |  | ) |

## operator=() [1/2]

multiTriSurface& operator= | ( | const multiTriSurface & |  | ) |

default

Copy assignment (default)

## operator=() [2/2]

multiTriSurface& operator= | ( | multiTriSurface && |  | ) |

delete

No move assignment.

## appendSurface()

bool appendSurface | ( | const word & | name,
|  | const realx3x3Vector & | vertices
| ) |  |

Definition at line 56 of file multiTriSurface.cpp.

References fatalErrorInFunction.

## numSurfaces()

uint32 numSurfaces | ( |  | ) | const

inline

Definition at line 81 of file multiTriSurface.hpp.

References List< T >::size(), and multiTriSurface::subSurfaces_.

Referenced by pFlow::TSFtoVTK::convertRealx3TypetriSurfaceFieldSeparate(), geometry::createPropertyId(), multiTriSurface::subSurfaceName(), multiTriSurface::subSurfaceNumPoints(), multiTriSurface::subSurfacePointRange(), multiTriSurface::subSurfaceRange(), and multiTriSurface::subSurfaceSize().

Here is the call graph for this function:
Here is the caller graph for this function:

## subSurfaces()

const subSurfaceList& subSurfaces | ( |  | ) | const

inline

Definition at line 86 of file multiTriSurface.hpp.

References multiTriSurface::subSurfaces_.

Referenced by pFlow::TSFtoVTK::convertRealx3TypetriSurfaceFieldSeparate().

Here is the caller graph for this function:

## subSurfaceRange()

rangeU32 subSurfaceRange | ( | uint32 | nSub | ) | const

inline

Definition at line 91 of file multiTriSurface.hpp.

References fatalErrorInFunction, fatalExit, multiTriSurface::numSurfaces(), and multiTriSurface::subSurfaces_.

Referenced by geometry::createPropertyId(), and multiTriSurface::subSurfaceSize().

Here is the call graph for this function:
Here is the caller graph for this function:

## subSurfacePointRange()

rangeU32 subSurfacePointRange | ( | uint32 | nSub | ) | const

inline

Definition at line 101 of file multiTriSurface.hpp.

References fatalErrorInFunction, fatalExit, multiTriSurface::numSurfaces(), and multiTriSurface::subSurfaces_.

Referenced by multiTriSurface::subSurfaceNumPoints().

Here is the call graph for this function:
Here is the caller graph for this function:

## clear()

void clear | ( |  | ) |

inline

Clear the content of object.

Definition at line 114 of file multiTriSurface.hpp.

References triSurface::clear(), and multiTriSurface::subSurfaces_.

Here is the call graph for this function:

## subSurfaceSize()

uint32 subSurfaceSize | ( | uint32 | nSub | ) | const

inline

Definition at line 121 of file multiTriSurface.hpp.

References Range< T >::numElements(), multiTriSurface::numSurfaces(), and multiTriSurface::subSurfaceRange().

Here is the call graph for this function:

## subSurfaceNumPoints()

uint32 subSurfaceNumPoints | ( | uint32 | nSub | ) | const

inline

Definition at line 133 of file multiTriSurface.hpp.

References Range< T >::numElements(), multiTriSurface::numSurfaces(), and multiTriSurface::subSurfacePointRange().

Here is the call graph for this function:

## subSurfaceName()

word subSurfaceName | ( | uint32 | nSub | ) | const

inline

Definition at line 145 of file multiTriSurface.hpp.

References multiTriSurface::numSurfaces(), and multiTriSurface::subSurfaces_.

Here is the call graph for this function:

## read()

bool read | ( | iIstream & | is,
|  | const IOPattern & | iop
| ) |  |

overridevirtual

Implements IOobject.

Definition at line 76 of file multiTriSurface.cpp.

References pFlow::endl(), fatalErrorInFunction, iIstream::findKeywordAndVal(), IOstream::name(), triSurface::read(), and multiTriSurface::subSurfaces_.

Referenced by geometry::read().

Here is the call graph for this function:
Here is the caller graph for this function:

## write()

bool write | ( | iOstream & | os,
|  | const IOPattern & | iop
| ) |  | const

overridevirtual

Implements IOobject.

Definition at line 91 of file multiTriSurface.cpp.

References IOstream::check(), FUNCTION_NAME, IOPattern::thisProcWriteData(), triSurface::write(), and iOstream::writeWordEntry().

Referenced by pFlow::operator<<(), and geometry::write().

Here is the call graph for this function:
Here is the caller graph for this function:

## Member Data Documentation

## subSurfaces_

subSurfaceList subSurfaces_

private

Definition at line 39 of file multiTriSurface.hpp.

Referenced by multiTriSurface::clear(), multiTriSurface::numSurfaces(), multiTriSurface::read(), multiTriSurface::subSurfaceName(), multiTriSurface::subSurfacePointRange(), multiTriSurface::subSurfaceRange(), and multiTriSurface::subSurfaces().

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

- src/phasicFlow/triSurface/multiTriSurface.hpp
- src/phasicFlow/triSurface/multiTriSurface.cpp