diff options
author | AnotherTest <ali.mpfard@gmail.com> | 2021-01-03 02:56:41 +0330 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-01-03 10:47:29 +0100 |
commit | 2b38b2f83b02f05677b20da38f503e92f7a6b195 (patch) | |
tree | 39a84ce5bf778a43efe36f20824a1fe16b375055 | |
parent | f3ecea1fb36ceca9127b62d67bc8eb6213e38b79 (diff) | |
download | serenity-2b38b2f83b02f05677b20da38f503e92f7a6b195.zip |
LibCore: Add a way to check if a property is readonly
-rw-r--r-- | Libraries/LibCore/Property.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Libraries/LibCore/Property.h b/Libraries/LibCore/Property.h index baf9e0812c..aa04e833fb 100644 --- a/Libraries/LibCore/Property.h +++ b/Libraries/LibCore/Property.h @@ -48,6 +48,7 @@ public: JsonValue get() const { return m_getter(); } const String& name() const { return m_name; } + bool is_readonly() const { return !m_setter; } private: String m_name; |