Module with the NoteType class’s attribute readers, writers, and accessors
Attributes
| [R] | anki21_database | |
| [R] | card_templates | The note type’s card template objects, as an array |
| [RW] | cloze | A boolean that indicates if this note type is a cloze-deletion note type |
| [RW] | css | The note type’s CSS |
| [R] | deck_id | The note type’s deck’s id |
| [R] | id | The note type’s id |
| [R] | last_modified_timestamp | The number of seconds since the 1970 epoch at which the note type was last modified |
| [R] | latex_postamble | The note type’s LaTeX postamble |
| [R] | latex_preamble | The note type’s LaTeX preamble |
| [R] | latex_svg | |
| [RW] | name | The note type’s name |
| [R] | note_fields | The note type’s field objects, as an array |
| [R] | req | |
| [R] | sort_field | The note type’s sort field |
| [R] | tags | |
| [R] | usn | The note type’s update sequence number |
| [R] | vers |
Instance Public methods
deck() Link
The note type’s deck
Source: show
# File lib/anki_record/note_type/note_type_attributes.rb, line 59 def deck return nil unless @deck_id anki21_database.find_deck_by id: @deck_id end
deck=(deck) Link
Sets the note type’s deck object
Source: show
# File lib/anki_record/note_type/note_type_attributes.rb, line 67 def deck=(deck) unless deck.instance_of?(AnkiRecord::Deck) raise ArgumentError, "You can only set this attribute to an instance of AnkiRecord::Deck." end @deck_id = deck.id end