class Cryap::Database::Models::Account

Direct Known Subclasses

Defined in:

models/users/account.cr

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from class Cryap::Database::UpdatableModel

changed? : Bool changed?, id id, reset_updates reset_updates, save save

Constructor methods inherited from class Cryap::Database::UpdatableModel

new(unpacker : Neo4j::PackStream::Unpacker) new

Class methods inherited from class Cryap::Database::UpdatableModel

from_bolt(unpacker : Neo4j::PackStream::Unpacker) from_bolt

Macros inherited from class Cryap::Database::UpdatableModel

field_setter(property_name) field_setter

Instance methods inherited from class Cryap::Database::Model

node_id : Int64 node_id, node_labels : Array(String) node_labels, paginate!(pagination : Cryap::API::Paginator, result : Array(String | Symbol), forward : Array(String | Symbol), column : Symbol, property : Symbol | Nil = nil, &) : Tuple(String, String | Nil) paginate!

Constructor methods inherited from class Cryap::Database::Model

new(unpacker : Neo4j::PackStream::Unpacker)
new(node : Neo4j::Node)
new

Class methods inherited from class Cryap::Database::Model

from_bolt(unpacker : Neo4j::PackStream::Unpacker)
from_bolt(io : IO)
from_bolt
, model_name model_name, paginate!(pagination : Cryap::API::Paginator, result : Array(String | Symbol), forward : Array(String | Symbol), column : Symbol, property : Symbol | Nil = nil, &) : Tuple(String, String | Nil) paginate!

Macros inherited from class Cryap::Database::Model

model(name) model, query!(&block) query!

Constructor Detail

def self.new(ap_id : URI, name : String, instance : String, display_name : String = name, id : KSUID = KSUID.new, shared_inbox_uri : URI = nil, summary : String = "", followers_uri : URI = URI.parse("#{ap_id}/followers"), outbox_uri : URI = URI.parse("#{ap_id}/outbox"), inbox_uri : URI = URI.parse("#{ap_id}/inbox"), manually_approves_followers : Bool = true, discoverable : Bool = true, bot : Bool = false, is_cat : Bool = false, created_at : Time = Time.utc, updated_at : Time = Time.utc) #

def self.new(unpacker : Neo4j::PackStream::Unpacker) #

Class Method Detail

def self.by_acct(acct : String) #

def self.by_apid(ap_id : URI) #

def self.by_id(id : String) #

def self.by_id(id : KSUID) #

def self.from_bolt(unpacker : Neo4j::PackStream::Unpacker) #

def self.get_instances #

def self.get_remote_accounts_ap_ids(skip : Int, limit : Int) #

def self.get_remote_inboxes #

Instance Method Detail

def acct #

def ap_id : URI #

def avatar #

def avatar=(avatar : KSUID | Media) #

def banner=(banner : KSUID | Media) #

def bookmarked_posts(pagination : Cryap::API::Paginator | Nil = nil) #

def bot=(value : Bool) #

def bot? : Bool #

def confirm_follow(followee : Account, activity_id : URI | Nil) #

def created_at : Time #

def delete #

def discoverable=(value : Bool) #

def discoverable? : Bool #

def display_name : String #

def display_name=(value : String) #

def follow_requests(pagination : Cryap::API::Paginator | Nil = nil) #

def follow_requests_count #

def followers(page : Int32) #

def followers(pagination : Cryap::API::Paginator | Nil = nil) #

def followers_count : Int32 #

def followers_uri : URI #

def following(page : Int32) #

def following(pagination : Cryap::API::Paginator | Nil = nil) #

def following_count : Int32 #

def follows?(account : Account) : Bool #

def get_follow_apid(to : Account) #

def id : KSUID #

def inbox_uri : URI #

def instance : String #

def is_cat=(value : Bool) #

def is_cat? : Bool #

def liked_posts(pagination : Cryap::API::Paginator | Nil = nil) #

def local? : Bool #

def local_followers #

def manually_approves_followers=(value : Bool) #

def manually_approves_followers? : Bool #

def name : String #

def outbox_uri : URI #

def posts(pagination : Cryap::API::Paginator, actor : LocalAccount | Nil = nil) #

def private_note(by : LocalAccount) #

def public_key #

def public_key=(key) #

def set_private_note(note : String | Nil, by : LocalAccount) #

def shared_inbox_uri : URI #

def statuses_count : Int32 #

def summary : String #

def summary=(value : String) #

def unfollow(followee : Account) #

def updated_at : Time #

def want_to_follow(followee : Account, activity_id : URI) #

def wants_to_follow?(account : Account) : Bool #