public class ArgsTest { private List <Object> args;
private ArgsTestCheckPoint checkPoint;
public enum ArgsTestCheckPoint
{
IS_NAME_CORRECT,IS_PASSWORD_CORRECT
} ArgsTest(ArgsTestCheckPoint checkPoint, Object ...objs) {
this.checkPoint=checkPoint;
for(Object obj:objs)
{
System.out.println(obj);
args.add(obj);
} }
public void perform() throws Exception
{
switch (checkPoint)
{
case IS_NAME_CORRECT:System.out.println((String)args.get(0)+(Integer)args.get(1));
break;
case IS_PASSWORD_CORRECT:System.out.println((Integer)args.get(0)+(String)args.get(1));
break;
default: }
} }
相关文章
- 3 Steps to Perform SSH Login Without Password Using ssh-keygen & ssh-copy-id
- linux xfce4普通用户 mount usb提示: Not authorized to perform operation
- rabbimq集群搭建报错:Error: unable TO perform an operation ON node 'rabbit@test3'. Please see diagnostics information AND suggestions below.
- Check if string contains a word then perform action
- SQL1092N The requested command or operation failed because the user ID does not have the authority to perform the requested command or operation.
- Caused by: java.sql.SQLException: Couldn't perform the operation getAutoCommit: You can't perform any operations on this connection. It has been automatically closed by Proxool for some reason (see lo
- 亚马逊EC2在linux 终端 you need to be root to perform this command问题解决
- libcurl 函数curl_easy_perform在release下崩溃的问题
- 删除文件夹时提示“You need permission to perform this action。。。”,如何解决?
- plsql启动报 Using filter for all users can lead to poor perform