Project

General

Profile

Actions

Developer Request #5144

closed

[cfg] Получение последнего подмодуля данного модуля

Added by Mikhail Chupilko over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Target version:
Start date:
07/23/2014
Due date:
% Done:

100%

Estimated time:
Published in build:
r816

Description

Предлагаю добавить функциональность получения последнего подмодуля. Что-то типа такого:

  public ru.ispras.retrascope.model.cfg.Module getLastElement(final Set<ru.ispras.retrascope.model.cfg.Module> c) {
    final Iterator<ru.ispras.retrascope.model.cfg.Module> itr = c.iterator();
    Object lastElement = itr.next();
    while(itr.hasNext()) {
        lastElement=itr.next();
    }
    return (ru.ispras.retrascope.model.cfg.Module)lastElement;
  }

Или не использовать тип Set для хранения подмодулей.

Actions #1

Updated by Sergey Smolov over 10 years ago

  • Status changed from New to Resolved
  • Target version set to 0.1
  • % Done changed from 0 to 100
  • Published in build set to r816

Для хранения подмодулей используем тип List.

Actions #2

Updated by Alexander Kamkin over 10 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF