📄 basiclistuos.java
字号:
/* BasicListUos.java
* ---------------------------------------------
* Copyright (c) 2001 University of Saskatchewan
* All Rights Reserved
* --------------------------------------------- */
package dslib.list;
import dslib.exception.*;
import dslib.base.*;
/** A descendant of interface SimpleListUos with added methods
to set the first item, and to access and set the first
remainder of the list. */
public interface BasicListUos extends SimpleListUos
{
/** Set the first item to x. <br>
PRECONDITION: <br>
<ul>
!isEmpty()
</ul>
@param x item to replace the first item */
public void setFirstItem(Object x) throws ContainerEmptyUosException;
/** The list formed by excluding the first item. <br>
PRECONDITION: <br>
<ul>
!isEmpty()
</ul> */
public BasicListUos firstRemainder() throws ContainerEmptyUosException;
/** Set the list to be list rem preceded by firstItem. <br>
PRECONDITION: <br>
<ul>
!isEmpty()
</ul>
@param rem the replacement list for firstRemainder() */
public void setFirstRemainder(BasicListUos rem) throws ContainerEmptyUosException;
/** Linear iterator for list initialized to first item. */
public LinearIteratorUos iterator();
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -