Sha256: 6e4d532388e55684121dfef616802e66ecdfa379463e1eabab80b4077b03a967

Contents?: true

Size: 891 Bytes

Versions: 16

Compression:

Stored size: 891 Bytes

Contents

#include <internal/values/config_int.hpp>

using namespace std;

namespace hocon {

    config_int::config_int(shared_origin origin, int value, string original_text) :
            config_number(move(origin), move(original_text)), _value(value) { }

    std::string config_int::transform_to_string() const {
        string s = config_number::transform_to_string();
        if (s.empty()) {
            return to_string(_value);
        } else {
            return s;
        }
    }

    unwrapped_value config_int::unwrapped() const {
        return _value;
    }

    int64_t config_int::long_value() const {
        return _value;
    }

    double config_int::double_value() const {
        return _value;
    }

    shared_value config_int::new_copy(shared_origin origin) const {
        return make_shared<config_int>(move(origin), _value, _original_text);
    }

}  // namespace hocon

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
facter-3.12.2.cfacter.20181217 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.12.1.cfacter.20181031 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.6.cfacter.20181031 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.12.1.cfacter.20181023 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.5.cfacter.20181022 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.12.0.cfacter.20181004 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.12.0.cfacter.20181001 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.12.0.cfacter.20180918 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.4.cfacter.20180821 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.3.cfacter.20180716 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.2.cfacter.20180612 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.9.6.cfacter.20180612 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.2.cfacter.20180606 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.9.6.cfacter.20180606 ext/facter/cpp-hocon/lib/src/values/config_int.cc
facter-3.11.0.cfacter.20180319 ext/facter/cpp-hocon/lib/src/values/config_int.cc
cfacter-3.11.0.rc.20180314 ext/facter/cpp-hocon/lib/src/values/config_int.cc