jaula API Reference version 1.4.0
JAULA::Value_Number_Int Class Reference

Class for handling numeric (int) values. More...

#include <jaula_value_number_int.h>

Inheritance diagram for JAULA::Value_Number_Int:
JAULA::Value

Public Member Functions

long getData (void) const
 Retrieves the value contained by the instance.
 
virtual void repr (std::ostream &ostr) const
 Represents the instance in a stream.
 
void set (long data)
 Establishes the contents of the instance.
 
virtual void set (Value const &origin) throw (Bad_Data_Type)
 Copies the contents of one instance into another.
 
 Value_Number_Int (long data=0)
 Constructor.
 
virtual ~Value_Number_Int ()
 Destructor.
 
- Public Member Functions inherited from JAULA::Value
ValueType getType (void) const
 Retrieves the value type for the instance.
 
Valueoperator= (Value const &orig) throw (Bad_Data_Type)
 Assignment operator.
 
virtual ~Value ()
 Destructor.
 

Private Attributes

long data_
 Container to hold the value itself.
 

Additional Inherited Members

- Public Types inherited from JAULA::Value
enum  ValueType {
  TYPE_NULL , TYPE_BOOLEAN , TYPE_STRING , TYPE_NUMBER ,
  TYPE_NUMBER_INT , TYPE_ARRAY , TYPE_OBJECT
}
 Enumeration of available value types. More...
 
- Static Public Member Functions inherited from JAULA::Value
static Valueduplicate (Value const &orig)
 Creates a duplicate of a value.
 
- Protected Member Functions inherited from JAULA::Value
 Value (ValueType Type)
 Constructor.
 

Detailed Description

Class for handling numeric (int) values.

This class is a container for JSON numeric values adapted to hold only integer values.
Author
Kombo Morongo moron.nosp@m.go66.nosp@m.6@gma.nosp@m.il.c.nosp@m.om

Constructor & Destructor Documentation

◆ Value_Number_Int()

JAULA::Value_Number_Int::Value_Number_Int ( long  data = 0)

Constructor.

Parameters
dataInitial value to be hold by the conatiner

◆ ~Value_Number_Int()

JAULA::Value_Number_Int::~Value_Number_Int ( )
virtual

Destructor.

Member Function Documentation

◆ getData()

long JAULA::Value_Number_Int::getData ( void  ) const

Retrieves the value contained by the instance.

References data_.

Referenced by JAULA::Value::duplicate(), and set().

◆ repr()

void JAULA::Value_Number_Int::repr ( std::ostream &  ostr) const
virtual

Represents the instance in a stream.

Parameters
ostrStream where the instance is to be represented.
Description
writes the instance content in JSON notation in a stream.

Implements JAULA::Value.

References data_.

◆ set() [1/2]

void JAULA::Value_Number_Int::set ( long  data)

Establishes the contents of the instance.

Parameters
dataValue to assign to the instance

References data_.

◆ set() [2/2]

void JAULA::Value_Number_Int::set ( Value const &  origin)
throw (Bad_Data_Type
)
virtual

Copies the contents of one instance into another.

Parameters
originReference to the value to be copied.
Exceptions
Bad_Data_TypeThis exception is launched in case that origin and destination value types are different.

Reimplemented from JAULA::Value.

References JAULA::Exception::addOrigin(), getData(), and JAULA::Value::set().

Field Documentation

◆ data_

long JAULA::Value_Number_Int::data_
private

Container to hold the value itself.

Referenced by getData(), repr(), and set().


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


Back to JAULA Project Documentation Page.

Go to JAULA Project Home Page.


Copyright (c) 2007, 2008, 2009 Kombo Morongo.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".

API Reference Generated for jaula by

doxygen

jaula project hosted by

SourceForge.net