Changeset 15 in libcf++


Ignore:
Timestamp:
06/14/15 03:03:32 (9 years ago)
Author:
cheese
Message:

#1 remove unused interface

Location:
trunk
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/cf/bin.h

    r11 r15  
    6363         */
    6464        cf::size_t size() const;
    65 
    66         /**
    67          * is empty
    68          * @return is empty ?
    69          */
    70         cf::bool_t empty() const;
    7165
    7266        /**
  • trunk/include/cf/network.h

    r14 r15  
    5050             */
    5151            cf::uint16_t port() const;
    52 
    53             /**
    54              * is empty ?
    55              * @return true; false
    56              */
    57             cf::bool_t empty() const;
    5852        };
    5953
  • trunk/include/cf/task.h

    r11 r15  
    99#include "cf/exception.h"
    1010
    11 #define SYNCHRONIZED(_s)    for (cf::task::scopedLock _sl(&_s) ; _sl.locked() ; _sl.unlock())
     11#define SYNCHRONIZED(_s)    for (cf::task::scopedLock _sl(&_s) ; _sl.isLocked() ; _sl.unlock())
    1212
    1313namespace cf
     
    4040             * @return true; false
    4141             */
    42             virtual cf::bool_t locked() const = 0;
     42            virtual cf::bool_t isLocked() const = 0;
    4343        };
    4444
     
    9090             * @return true; false
    9191             */
    92             cf::bool_t locked() const;
     92            cf::bool_t isLocked() const;
    9393        };
    9494
     
    119119             * @return true; false
    120120             */
    121             cf::bool_t locked() const;
     121            cf::bool_t isLocked() const;
    122122
    123123            /**
  • trunk/src/bin.cpp

    r11 r15  
    3838{
    3939    return mBin.size();
    40 }
    41 
    42 cf::bool_t cf::bin::empty() const
    43 {
    44     return mBin.empty();
    4540}
    4641
  • trunk/src/codec.cpp

    r7 r15  
    1919    throw (cf::exception)
    2020{
    21     if (in.empty())
     21    if (in.size() == 0)
    2222        THROW_EXCEPTION("input is empty");
    2323
     
    182182    throw (cf::exception)
    183183{
    184     if (in.empty())
     184    if (in.size() == 0)
    185185        THROW_EXCEPTION("input is empty");
    186186
  • trunk/src/logger.cpp

    r7 r15  
    169169        if (!mOpenMutex.trylock())
    170170        {
    171             while (mOpenMutex.locked())
     171            while (mOpenMutex.isLocked())
    172172                /* waiting */;
    173173
     
    211211        if (!mRenameMutex.trylock())
    212212        {
    213             while (mRenameMutex.locked())
     213            while (mRenameMutex.isLocked())
    214214                /* waiting */;
    215215
  • trunk/src/network.cpp

    r14 r15  
    153153}
    154154
    155 cf::bool_t cf::network::host::empty() const
    156 {
    157     return (address().empty() || port() == 0) ? true : false;
    158 }
    159 
    160155cf::network::tcp::tcp(const cf::socket_t attachedSocket)
    161156    throw (cf::exception)
     
    351346    throw (cf::exception)
    352347{
    353     if (in.empty())
    354         THROW_EXCEPTION("send data is null or zero-bytes");
     348    if (in.size() == 0)
     349        THROW_EXCEPTION("send data is zero-bytes");
    355350
    356351    cf::char_t * buf = reinterpret_cast<cf::char_t *>(in.buffer());
  • trunk/src/task.cpp

    r11 r15  
    136136}
    137137
    138 cf::bool_t cf::task::mutex::locked() const
     138cf::bool_t cf::task::mutex::isLocked() const
    139139{
    140140    return mIsLocked;
     
    162162}
    163163
    164 cf::bool_t cf::task::scopedLock::locked() const
    165 {
    166     return mSynchronizer->locked();
     164cf::bool_t cf::task::scopedLock::isLocked() const
     165{
     166    return mSynchronizer->isLocked();
    167167}
    168168
  • trunk/test/makefile

    r13 r15  
    2222LIB_NAME        = cf++
    2323
    24 INCLUDES        = -I../include -I../src
     24INCLUDES        = -I../include
    2525LIBRARIES       = -L$(BUILD_PATH) -l$(LIB_NAME) $(LIBS)
    2626LIBRARY_PATH    = .
Note: See TracChangeset for help on using the changeset viewer.