Class: Google::Apis::LibraryagentV1::GoogleExampleLibraryagentV1Book
- Inherits:
-
Object
- Object
- Google::Apis::LibraryagentV1::GoogleExampleLibraryagentV1Book
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/libraryagent_v1/classes.rb,
generated/google/apis/libraryagent_v1/representations.rb,
generated/google/apis/libraryagent_v1/representations.rb
Overview
A single book in the library.
Instance Attribute Summary collapse
-
#author ⇒ String
The name of the book author.
-
#name ⇒ String
The resource name of the book.
-
#read ⇒ Boolean
(also: #read?)
Value indicating whether the book has been read.
-
#title ⇒ String
The title of the book.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleExampleLibraryagentV1Book
constructor
A new instance of GoogleExampleLibraryagentV1Book.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleExampleLibraryagentV1Book
Returns a new instance of GoogleExampleLibraryagentV1Book.
51 52 53 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 51 def initialize(**args) update!(**args) end |
Instance Attribute Details
#author ⇒ String
The name of the book author.
Corresponds to the JSON property author
32 33 34 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 32 def @author end |
#name ⇒ String
The resource name of the book. Book names have the form shelves/
shelf_id/
books/
book_id`. The name is ignored when creating a book.
Corresponds to the JSON property
name`
38 39 40 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 38 def name @name end |
#read ⇒ Boolean Also known as: read?
Value indicating whether the book has been read.
Corresponds to the JSON property read
43 44 45 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 43 def read @read end |
#title ⇒ String
The title of the book.
Corresponds to the JSON property title
49 50 51 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 49 def title @title end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
56 57 58 59 60 61 |
# File 'generated/google/apis/libraryagent_v1/classes.rb', line 56 def update!(**args) @author = args[:author] if args.key?(:author) @name = args[:name] if args.key?(:name) @read = args[:read] if args.key?(:read) @title = args[:title] if args.key?(:title) end |