# Class: Attribute

## Attribute()

Attribute is an abstract concept which has two real uses - label (key - value pair) and relation (representing named relationship between source and target note)

## Constructor

#### new Attribute()

Source:
  - becca/entities/attribute.js, line 15

### Extends

- AbstractEntity

### Members

#### attributeId :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 46

#### isInheritable :boolean

##### Type:

- boolean

Source:
  - becca/entities/attribute.js, line 58

#### name :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 52

#### noteId :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 48

#### position :int

##### Type:

- int

Source:
  - becca/entities/attribute.js, line 54

#### type :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 50

#### utcDateModified :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 60

#### value :string

##### Type:

- string

Source:
  - becca/entities/attribute.js, line 56

### Methods

#### getNote() → {Note|null}

Source:
  - becca/entities/attribute.js, line 114

##### Returns:

Type
  Note | null

#### getTargetNote() → {Note|null}

Source:
  - becca/entities/attribute.js, line 121

##### Returns:

Type
  Note | null

#### isDefinition() → {boolean}

Source:
  - becca/entities/attribute.js, line 136

##### Returns:

Type
  boolean

#### markAsDeleted(deleteIdopt)

Mark the entity as (soft) deleted. It will be completely erased later. This is a low level method, for notes and branches use `note.deleteNote()` and 'branch.deleteBranch()` instead.

##### Parameters:

Name | Type | Attributes | Default | Description
--- | --- | --- | --- | ---
`deleteId` |  | <optional> | null |

Overrides:
  - AbstractEntity#markAsDeleted
Source:
  - becca/entities/abstract_entity.js, line 118

#### save() → {AbstractEntity}

Saves entity - executes SQL, but doesn't commit the transaction on its own

Overrides:
  - AbstractEntity#save
Source:
  - becca/entities/abstract_entity.js, line 73

##### Returns:

Type
  AbstractEntity