xtd 0.2.0
Loading...
Searching...
No Matches
xtd::web::css::property Class Reference
Inheritance diagram for xtd::web::css::property:
xtd::object

Public Constructors

 property (const xtd::string &value)
 property (const property &)=default
property & operator= (const property &)=default
 property (property &&)=default
property & operator= (property &&)=default

Operators

 operator xtd::string () noexcept

Public Properties

auto value () const noexcept -> const xtd::string &
template<class value_t>
auto value () const noexcept -> value_t

Public Methods

auto to_boolean () const -> bool
auto to_double () const -> double
auto to_int8 () const -> xtd::sbyte
auto to_int16 () const -> xtd::int16
auto to_int32 () const -> xtd::int32
auto to_int64 () const -> xtd::int64
auto to_intptr () const -> xtd::intptr
auto to_single () const -> xtd::single
auto to_string () const noexcept -> xtd::string override
 Returns a xtd::string that represents the current object.
auto to_uint8 () const -> xtd::byte
auto to_uint16 () const -> xtd::uint16
auto to_uint32 () const -> xtd::uint32
auto to_uint64 () const -> xtd::uint64
auto to_uintptr () const -> xtd::uintptr
template<class value_t>
auto to () const -> value_t

Public Static Methods

static auto from (bool value) -> property
static auto from (double value) -> property
static auto from (xtd::single value) -> property
static auto from (xtd::sbyte value) -> property
static auto from (xtd::int16 value) -> property
static auto from (xtd::int32 value) -> property
static auto from (xtd::int64 value) -> property
static auto from (const xtd::string &value) -> property
static auto from (xtd::byte value) -> property
static auto from (xtd::uint16 value) -> property
static auto from (xtd::uint32 value) -> property
static auto from (xtd::uint64 value) -> property
static auto from (const auto &value) -> property

Additional Inherited Members

 object ()=default
 Create a new instance of the ultimate base class object.
virtual bool equals (const object &obj) const noexcept
 Determines whether the specified object is equal to the current object.
virtual xtd::size get_hash_code () const noexcept
 Serves as a hash function for a particular type.
virtual type_object get_type () const noexcept
 Gets the type of the current instance.
template<class object_t>
xtd::unique_ptr_object< object_t > memberwise_clone () const
 Creates a shallow copy of the current object.
template<class object_a_t, class object_b_t>
static bool equals (const object_a_t &object_a, const object_b_t &object_b) noexcept
 Determines whether the specified object instances are considered equal.
template<class object_a_t, class object_b_t>
static bool reference_equals (const object_a_t &object_a, const object_b_t &object_b) noexcept
 Determines whether the specified object instances are the same instance.

Member Function Documentation

◆ to_string()

auto xtd::web::css::property::to_string ( ) const -> xtd::string
inlinenodiscardoverridevirtualnoexcept

Returns a xtd::string that represents the current object.

Returns
A string that represents the current object.
Examples
The following code example demonstrates what to_string returns.
#include <xtd/xtd>
namespace examples {
namespace object_test {
class object1 : public object {
};
}
}
auto main() -> int {
console::write_line(obj1->to_string());
ptr<object> obj2 = new_ptr<date_time>(1971, 1, 5, 23, 5, 0);
console::write_line(obj2->to_string());
console::write_line(obj3->to_string());
}
// This code produces the following output :
//
// examples::object_test::object1
// Tue Jan 5 23:05:00 1971
// false
static void write_line()
Writes the current line terminator to the standard output stream using the specified format informati...
object()=default
Create a new instance of the ultimate base class object.
xtd::sptr< type_t > ptr
The xtd::ptr object is a shared pointer.
Definition ptr.hpp:27
ptr< type_t > new_ptr(args_t &&... args)
The xtd::new_ptr operator creates a xtd::ptr object.
Definition new_ptr.hpp:24

Reimplemented from xtd::object.


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