Signature.create Sync
var signature = Signature.create(name, email, time, offset);
Parameters | Type | |
---|
name | String | name of the person |
email | String | email of the person |
time | Number | time (in seconds from epoch) when the action happened |
offset | Number | timezone offset (in minutes) for the time |
Returns | |
---|
Signature | new signature, in case of error NULL |
Signature.default Async
Signature.default(repo).then(function(signature) {
// Use signature
});
Signature.fromBuffer Async
Signature.fromBuffer(buf).then(function(signature) {
// Use signature
});
Parameters | Type | |
---|
buf | String | signature string |
Signature.now Sync
var signature = Signature.now(name, email);
Parameters | Type | |
---|
name | String | name of the person |
email | String | email of the person |
Returns | |
---|
Signature | new signature, in case of error NULL |
Signature#toString Sync
var string = signature.toString(withTime);
Standard string representation of an author.
Parameters | Type | |
---|
withTime | Boolean | Whether or not to include timestamp |
Returns | |
---|
String | Representation of the author. |
Instance Variables
Variable | Type | Description |
---|
email | String | |
name | String | |
when | Time | |