Module: Vedeu::Editor::Collection Private

Includes:
Repositories::Assemblage
Included in:
Line, Lines
Defined in:
lib/vedeu/editor/collection.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Used by Lines and Line to fetch an item from the respective collection.

Instance Method Summary collapse

Instance Method Details

#[](index) ⇒ void Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

This method returns an undefined value.

Return an individual element or collection of elements (if the given index is a Range).

Parameters:

  • index (Fixnum|Range)

#any?(&block) ⇒ Boolean Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a boolean indicating whether the collection is not empty.

Parameters:

  • block (Proc)

Returns:

#by_index(index) ⇒ String

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Fetches an item from a collection.

Parameters:

  • index (Fixnum)

Returns:

  • (String)


20
21
22
# File 'lib/vedeu/editor/collection.rb', line 20

def by_index(index)
  Vedeu::Editor::Item.by_index(collection, index)
end

#each(&block) ⇒ Enumerator Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Provides iteration over the collection.

Parameters:

  • block (Proc)

Returns:

  • (Enumerator)

#empty?Boolean Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a boolean indicating whether the collection is empty.

Returns:

#eql?(other) ⇒ Boolean Also known as: == Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

An object is equal when its values are the same.

Parameters:

  • other (void)

Returns:

#sizeFixnum Originally defined in module Repositories::Assemblage

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Return the size of the collection.

Returns:

  • (Fixnum)