de.tsl2.nano.incubation.terminal.IContainer Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of tsl2.nano.terminal Show documentation
Show all versions of tsl2.nano.terminal Show documentation
TSL2 Framework Terminal (Console Application Framework named SIShell, providing Actions, Options, Commands, Inputs, lots of Selectors, PlatformManagement)
/*
* File: $HeadURL$
* Id : $Id$
*
* created by: Tom
* created on: 23.12.2014
*
* Copyright: (c) Thomas Schneider 2014, all rights reserved
*/
package de.tsl2.nano.incubation.terminal;
import java.io.InputStream;
import java.io.PrintStream;
import java.util.List;
import java.util.Map;
import java.util.Properties;
/**
* interface for items having child items
*
* @author Tom
* @version $Revision$
*/
public interface IContainer extends IItem {
I getValue(int i);
/**
* @return child items depending on the current context.
*/
@SuppressWarnings("rawtypes")
public List extends IItem> getNodes(final Map context);
/**
* adds a child
*
* @param item item
* @return true, if successful added
*/
> boolean add(II item);
/**
* removes a child
*
* @param item item
* @return true, if successful removed
*/
> boolean remove(II item);
/**
* evaluates the next child node depending on the current environment
* @param in input stream
* @param out terminal output
* @param env current terminal environment
* @return normally the container itself
*/
> II next(InputStream in, PrintStream out, Properties env);
}