module Oid::Components::Application::Helper

Defined in:

Instance Method Summary

Instance Method Detail

def add_application(value : Oid::Controller::Application) : Entitas::Entity #

Add a Oid::Components::Application to the entity. Returns self to allow chainables

entity.add_application(1)

def add_component_application : Entitas::Entity #

Add a Oid::Components::Application to the entity. Returns self to allow chainables

entity.add_component_application

def add_component_application(**args) : Entitas::Entity #

Add a Oid::Components::Application to the entity. Returns self to allow chainables

entity.add_component_application

def application : Oid::Components::Application #

Will return the component that is a Oid::Components::Application or raise


def application? : Bool #

Alias. See #has_application?


def del_application : Entitas::Entity #

Delete Oid::Components::Application from the entity. Returns self to allow chainables

entity.del_application
entity.application # => nil

def del_component_application : Entitas::Entity #

Delete Oid::Components::Application from the entity. Returns self to allow chainables

entity.del_application
entity.application # => nil

def get_component_application : Oid::Components::Application #

Will return the component that is a Oid::Components::Application or raise


def has_application? : Bool #

Will return true if the entity has an component Oid::Components::Application or false if it does not


def has_component_application? : Bool #

Will return true if the entity has an component Oid::Components::Application or false if it does not


def remove_application #

Append. Alias for #del_application


def remove_component_application #

Append. Alias for #del_component_application


def replace_application(component : Oid::Components::Application) #

Will replace the current component with the new one provided

entity.replace_component_application(new_comp)
entity.get_application # => (new_comp)

def replace_application(value : Oid::Controller::Application) #

Will replace the current component with the new one generated from the provided arguments

entity.replace_application(value: 1)
entity.get_application # => (new_comp)

or

entity.replace_application(1)
entity.get_application # => (new_comp)

def replace_component_application(component : Oid::Components::Application) #

Append. Alias for #replace_application


def replace_component_application(**args) #

Will replace the current component with the new one generated from the provided arguments

entity.replace_application
entity.get_application # => (new_comp)