Changeset 19:280541440d22 in xplra for src/client/c


Ignore:
Timestamp:
02/03/13 13:46:17 (12 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

Getting multiple values works

Location:
src/client/c/hu/varadiistvan/xplra
Files:
4 added
4 edited

Legend:

Unmodified
Added
Removed
  • src/client/c/hu/varadiistvan/xplra/Exception.h

    r14 r19  
    177177     * Construct the exception
    178178     */
    179     NotConnectedException();
     179    NotConnectedException() throw();
     180};
     181
     182//------------------------------------------------------------------------------
     183
     184/**
     185 * Exception thrown when we want to get or set a dataref in a
     186 * MultiBuffer into or from a value of the wrong type.
     187 */
     188class TypeMismatchException : public Exception
     189{
     190public:
     191    /**
     192     * Construct the exception
     193     */
     194    TypeMismatchException() throw();
     195};
     196
     197//------------------------------------------------------------------------------
     198
     199/**
     200 * Exception thrown when we want to get or set a dataref with an
     201 * invalid ID.
     202 */
     203class InvalidIDException : public Exception
     204{
     205public:
     206    /**
     207     * Construct the exception
     208     */
     209    InvalidIDException() throw();
    180210};
    181211
     
    221251//------------------------------------------------------------------------------
    222252
    223 inline NotConnectedException::NotConnectedException() :
     253inline NotConnectedException::NotConnectedException() throw() :
    224254    Exception("xplra::NotConnectedException: not connected to the simulator")
     255{
     256}
     257
     258//------------------------------------------------------------------------------
     259//------------------------------------------------------------------------------
     260
     261inline TypeMismatchException::TypeMismatchException() throw() :
     262    Exception("xplra::TypeMismatchException")
     263{
     264}
     265
     266//------------------------------------------------------------------------------
     267//------------------------------------------------------------------------------
     268
     269inline InvalidIDException::InvalidIDException() throw() :
     270    Exception("xplra::InvalidIDException")
    225271{
    226272}
  • src/client/c/hu/varadiistvan/xplra/Makefile.am

    r14 r19  
    44
    55libxplra_la_SOURCES=\
     6        Exception.cc    \
    67        XPlane.cc       \
    7         Exception.cc    \
     8        MultiBuffer.cc  \
     9        MultiGetter.cc  \
    810        xplra.cc
    911
     
    1618include_xplradir=$(includedir)/hu/varadiistvan/xplra
    1719include_xplra_HEADERS=\
     20        Exception.h     \
    1821        XPlane.h        \
    19         Exception.h     \
     22        MultiBuffer.h   \
     23        MultiGetter.h   \
    2024        xplra.h
  • src/client/c/hu/varadiistvan/xplra/XPlane.cc

    r18 r19  
    5353//------------------------------------------------------------------------------
    5454
    55 inline void XPlane::checkStream() throw(NotConnectedException, IOException)
     55void XPlane::checkStream() throw(NotConnectedException, IOException)
    5656{
    5757    if (stream==0) {
     
    9191//------------------------------------------------------------------------------
    9292
    93 inline void XPlane::checkResult() throw(ProtocolException)
     93void XPlane::checkResult() throw(ProtocolException)
    9494{
    9595    uint8_t result = stream->readU8();
  • src/client/c/hu/varadiistvan/xplra/XPlane.h

    r18 r19  
    270270    void setArray(const char* name, uint8_t type, size_t length,
    271271                  size_t offset) throw(Exception);
     272
     273    friend class MultiBuffer;
     274    friend class MultiGetter;
     275    friend class MultiSetter;
    272276};
    273277
Note: See TracChangeset for help on using the changeset viewer.