Leosac  0.8.0
Open Source Access Control
Leosac::Auth::IZone Class Referenceabstract

The interface for zones. More...

#include <IZone.hpp>

+ Inheritance diagram for Leosac::Auth::IZone:
+ Collaboration diagram for Leosac::Auth::IZone:

Public Types

enum  Type { Type::PHYSICAL = 0x00, Type::LOGICAL = 0x01 }
 Zone's type. More...
 

Public Member Functions

virtual ZoneId id () const =0
 
virtual std::string alias () const =0
 
virtual std::string description () const =0
 
virtual Type type () const =0
 
virtual void alias (const std::string &alias)=0
 
virtual void description (const std::string &desc)=0
 
virtual void type (Type t)=0
 
virtual void clear_children ()=0
 
virtual void clear_doors ()=0
 
virtual void add_door (DoorLPtr door)=0
 
virtual void add_child (ZoneLPtr zone)=0
 
virtual std::vector< ZoneLPtrchildren () const =0
 Retrieve the children zones. More...
 
virtual std::vector< DoorLPtrdoors () const =0
 Retrieve the doors associated with the zones. More...
 

Detailed Description

The interface for zones.

A zone is a hierarchical container for doors and other zones. It allows users to better organize their doors and allows easier schedule management.

A zone have one of two Type and any number of doors and child zones.

There is a few rules to respect:

  • Cycles are forbidden in parent/children relationship.
  • While a zone can have multiple Type::LOGICAL parent, it can only have one Type::PHYSICAL parent.

Definition at line 47 of file IZone.hpp.

Member Enumeration Documentation

◆ Type

Zone's type.

Enumerator
PHYSICAL 
LOGICAL 

Definition at line 53 of file IZone.hpp.

Member Function Documentation

◆ add_child()

virtual void Leosac::Auth::IZone::add_child ( ZoneLPtr  zone)
pure virtual

Implemented in Leosac::Auth::Zone.

◆ add_door()

virtual void Leosac::Auth::IZone::add_door ( DoorLPtr  door)
pure virtual

Implemented in Leosac::Auth::Zone.

◆ alias() [1/2]

virtual std::string Leosac::Auth::IZone::alias ( ) const
pure virtual

Implemented in Leosac::Auth::Zone.

◆ alias() [2/2]

virtual void Leosac::Auth::IZone::alias ( const std::string &  alias)
pure virtual

Implemented in Leosac::Auth::Zone.

◆ children()

virtual std::vector<ZoneLPtr> Leosac::Auth::IZone::children ( ) const
pure virtual

Retrieve the children zones.

Implemented in Leosac::Auth::Zone.

◆ clear_children()

virtual void Leosac::Auth::IZone::clear_children ( )
pure virtual

Implemented in Leosac::Auth::Zone.

◆ clear_doors()

virtual void Leosac::Auth::IZone::clear_doors ( )
pure virtual

Implemented in Leosac::Auth::Zone.

◆ description() [1/2]

virtual std::string Leosac::Auth::IZone::description ( ) const
pure virtual

Implemented in Leosac::Auth::Zone.

◆ description() [2/2]

virtual void Leosac::Auth::IZone::description ( const std::string &  desc)
pure virtual

Implemented in Leosac::Auth::Zone.

◆ doors()

virtual std::vector<DoorLPtr> Leosac::Auth::IZone::doors ( ) const
pure virtual

Retrieve the doors associated with the zones.

Implemented in Leosac::Auth::Zone.

◆ id()

virtual ZoneId Leosac::Auth::IZone::id ( ) const
pure virtual

Implemented in Leosac::Auth::Zone.

◆ type() [1/2]

virtual Type Leosac::Auth::IZone::type ( ) const
pure virtual

Implemented in Leosac::Auth::Zone.

◆ type() [2/2]

virtual void Leosac::Auth::IZone::type ( Type  t)
pure virtual

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