From 8bdf0acac956101a8d176efbc673e9be79dba904 Mon Sep 17 00:00:00 2001 From: Bon-Yong Lee Date: Tue, 13 Nov 2012 17:31:41 +0900 Subject: [PATCH] [Title] Share RI for Prompter#batch(Collection) [Desc.] Share first implement for collaboration [Issue] #7420 --- .../org/tizen/common/core/command/UserField.java | 58 ++++++++++++++++++++-- 1 file changed, 55 insertions(+), 3 deletions(-) diff --git a/org.tizen.common/src/org/tizen/common/core/command/UserField.java b/org.tizen.common/src/org/tizen/common/core/command/UserField.java index 38d544d..8fb7507 100755 --- a/org.tizen.common/src/org/tizen/common/core/command/UserField.java +++ b/org.tizen.common/src/org/tizen/common/core/command/UserField.java @@ -1,17 +1,61 @@ +/* + * Common + * + * Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved. + * + * Contact: + * BonYong Lee + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * Contributors: + * - S-Core Co., Ltd + * + */ package org.tizen.common.core.command; import java.util.Arrays; import java.util.Collection; +/** + *

+ * UserField. + * + * User input sepecification + * + *

+ * + * @author BonYong Lee{@literal } (S-Core) + */ public class UserField { protected final String id; protected final String message; - protected boolean bModify; - protected Class type; + /** + *
    + *
  • String - text, normal input
  • + *
  • char[] - password, secured input
  • + *
  • String[] - ComboBox
  • + *
  • File - File selector
  • + *
  • boolean - checkbox, selection input
  • + *
+ */ + protected final Class type; + + protected boolean bModify = true; protected Object value; @@ -23,13 +67,16 @@ public class UserField public UserField( final String id, - final String message + final String message, + final Class type ) { this.id = id; this.message = message; + this.type = type; } + public String getId() { return this.id; @@ -69,6 +116,11 @@ public class UserField this.validator = validator; } + public Collection getChildren() + { + return this.children; + } + public void addChild( final UserField... children ) { this.children.addAll( Arrays.asList( children ) ); -- 2.7.4