DATABIND: add the boilerplate 81/22081/2
authorjaeyeol lee <jaeyeol148.lee@samsung.com>
Thu, 29 May 2014 08:05:44 +0000 (17:05 +0900)
committerjaeyeol lee <jaeyeol148.lee@samsung.com>
Thu, 29 May 2014 08:10:04 +0000 (17:10 +0900)
change the class name

Change-Id: Icd8717c8e9d7c6b2950cbd1e47628a528bfaceb5
Signed-off-by: jaeyeol lee <jaeyeol148.lee@samsung.com>
14 files changed:
org.tizen.webuibuilder/src/org/tizen/webuibuilder/gef/commands/SetDataSourceCommand.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/gef/commands/SetPartOpenUrlEventCommand.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/gef/commands/SetViewModelCommand.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/gef/figure/TooltipFigure.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/gef/policies/DesignerXYLayoutEditPolicy.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/DataBindingDnDManager.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/DataBindingEventDelegater.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/DataBindingHelper.java [moved from org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/DataBindingTooltipParser.java with 90% similarity]
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/DataBindingPage.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/actions/SetTargetAction.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/model/BindingDataSetEvent.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/model/BindingInfo.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/model/DataBindingTooltipData.java
org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/views/databinding/model/IBindingDataSetListener.java

index 275cc13..715ebf9 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.gef.commands;
 
 import java.util.ArrayList;
index d645bd5..e86b734 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.gef.commands;
 
 import org.eclipse.gef.commands.Command;
index 4c9fde7..def1d70 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.gef.commands;
 
 import java.util.List;
index 090c86a..86dd0df 100644 (file)
@@ -15,7 +15,7 @@ import org.eclipse.swt.graphics.Font;
 import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.widgets.Display;
 import org.tizen.webuibuilder.animator.ui.views.timeline.common.ColorResource;
-import org.tizen.webuibuilder.ui.views.databinding.DataBindingTooltipParser;
+import org.tizen.webuibuilder.ui.views.databinding.DataBindingHelper;
 import org.tizen.webuibuilder.ui.views.databinding.model.DataBindingTooltipData;
 
 
@@ -51,7 +51,7 @@ public class TooltipFigure extends Figure {
         
 //        txt =
 //                "text: model0.title, attr: { href: model0.url, title: model0.detail },";
-        List<DataBindingTooltipData> dataList = DataBindingTooltipParser.parse(txt);
+        List<DataBindingTooltipData> dataList = DataBindingHelper.parse(txt);
         DataBindingTooltipInnerFigure child = null;
 
         for (DataBindingTooltipData data : dataList) {
index ff449c0..469c270 100644 (file)
@@ -55,7 +55,7 @@ import org.tizen.webuibuilder.model.descriptors.ConstantDescriptor;
 import org.tizen.webuibuilder.ui.editor.dnd.listener.PageDesignerDropTargetListener;
 import org.tizen.webuibuilder.ui.editor.ruler.DesignerGuide;
 import org.tizen.webuibuilder.ui.editor.ruler.commands.ChangeGuideCommand;
-import org.tizen.webuibuilder.ui.views.databinding.DataBindingTooltipParser;
+import org.tizen.webuibuilder.ui.views.databinding.DataBindingHelper;
 
 
 public class DesignerXYLayoutEditPolicy extends HoverViewerXYLayoutEditPolicy {
@@ -190,7 +190,7 @@ public class DesignerXYLayoutEditPolicy extends HoverViewerXYLayoutEditPolicy {
                             item.addListener(SWT.Selection, new Listener() {
                                 public void handleEvent(Event e) {
                                     String str = targetPart.getProperty(BuilderConstants.ATTRIBUTE_DATA_BIND).getValue();
-                                    final String info = DataBindingTooltipParser.makeInfoString(targetPart, property2.getValue(), displayName, value, str);
+                                    final String info = DataBindingHelper.makeInfoString(targetPart, property2.getValue(), displayName, value, str);
                                     command =
                                             new SetPartPropertyCommand(targetPart, BuilderConstants.ATTRIBUTE_DATA_BIND,
                                                                        info);
index ba4c36e..c8c7b46 100644 (file)
@@ -140,7 +140,7 @@ public class DataBindingDnDManager {
                         dataType = treeItemData.getObjectType();
                     }
 
-                    String viewModelInfo = DataBindingTooltipParser.makeViewModelInfo(selection[0]);
+                    String viewModelInfo = DataBindingHelper.makeViewModelInfo(selection[0]);
                     
                     // FIXME "id"
                     DataBindingTemplate dataBindingTemplate =
index 56f0854..1a4291e 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding;
 
 import org.eclipse.gef.commands.CommandStack;
@@ -1,4 +1,24 @@
-
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding;
 
@@ -14,7 +34,7 @@ import org.tizen.webuibuilder.ui.views.databinding.model.DataBindingTooltipData;
 import org.tizen.webuibuilder.ui.views.databinding.model.TreeItemData;
 
 
-public class DataBindingTooltipParser {
+public class DataBindingHelper {
     public static List<DataBindingTooltipData> parse(String txt) {
         List<DataBindingTooltipData> list = new ArrayList<DataBindingTooltipData>();
         DataBindingTooltipData data = null;
@@ -181,7 +201,7 @@ public class DataBindingTooltipParser {
         String string = "";
         
         if ((str != null) && (!str.isEmpty())) {
-            Map<String, String> bindingInfos = DataBindingTooltipParser.parseToMap(str);
+            Map<String, String> bindingInfos = DataBindingHelper.parseToMap(str);
             
             if (bindingInfos.containsKey(value)) {
                 bindingInfos.remove(value);
@@ -195,7 +215,7 @@ public class DataBindingTooltipParser {
                 bindingInfos.put(value, viewModelInfo);
             }
                         
-            string = DataBindingTooltipParser.makeStringFromMap(bindingInfos);
+            string = DataBindingHelper.makeStringFromMap(bindingInfos);
         } else {
             if ((displayName != null) && (!displayName.isEmpty())) {
                 string = value + ": { " + displayName + ": " + viewModelInfo + " }";
@@ -242,7 +262,7 @@ public class DataBindingTooltipParser {
                         .getData("TREEITEMDATA")).getObjectType().equals("Array"))) {
             viewModelInfo = BuilderConstants.DATABINDING_ARRAYITEM_VALUE_PREFIX + treeItem.getText();
         } else {
-            viewModelInfo = DataBindingTooltipParser.makeViewModelInfoString(treeItem);
+            viewModelInfo = DataBindingHelper.makeViewModelInfoString(treeItem);
         }
         return viewModelInfo;
     }
index e2d2cbb..817a9d7 100644 (file)
@@ -304,7 +304,7 @@ public class DataBindingPage extends Page implements IBindingDataSetListener {
                         part.getProperty(BuilderConstants.ATTRIBUTE_DATA_BIND).getValue();
                 
                 if ((propertyValue != null) && (!propertyValue.isEmpty())) {
-                    Map<String, String> bindingInfos = DataBindingTooltipParser.parseToMap(propertyValue);
+                    Map<String, String> bindingInfos = DataBindingHelper.parseToMap(propertyValue);
                     Object[] bindingTypes = bindingInfos.keySet().toArray();
                     for (Object bindingType : bindingTypes) {
                         String key = bindingType.toString();
@@ -847,7 +847,7 @@ public class DataBindingPage extends Page implements IBindingDataSetListener {
     public void setBindingInfoToPart(Part targetPart, String viewModelInfo, String infoDisplayName,
                                      String infoValue) {
         String str = targetPart.getProperty(BuilderConstants.ATTRIBUTE_DATA_BIND).getValue();
-        final String info = DataBindingTooltipParser.makeInfoString(targetPart, viewModelInfo, infoDisplayName, infoValue, str);
+        final String info = DataBindingHelper.makeInfoString(targetPart, viewModelInfo, infoDisplayName, infoValue, str);
         getCommandStackFromPageDesigner().execute(new SetPartPropertyCommand(targetPart, BuilderConstants.ATTRIBUTE_DATA_BIND, info));
         
     }
@@ -1029,12 +1029,12 @@ public class DataBindingPage extends Page implements IBindingDataSetListener {
                     String propertyValue =
                             part.getProperty(BuilderConstants.ATTRIBUTE_DATA_BIND).getValue();
                     if ((propertyValue != null) && (!propertyValue.isEmpty())) {
-                        Map<String, String> bindingInfos = DataBindingTooltipParser.parseToMap(propertyValue);
+                        Map<String, String> bindingInfos = DataBindingHelper.parseToMap(propertyValue);
                         Object[] bindingTypes = bindingInfos.keySet().toArray();
                         for (Object bindingType : bindingTypes) {
                             if ((tableTypeValue != null) && (bindingType.toString().equals(tableTypeValue))) {
                                 bindingInfos.remove(bindingType);
-                                removeInfoTableItem(part, DataBindingTooltipParser.makeStringFromMap(bindingInfos));
+                                removeInfoTableItem(part, DataBindingHelper.makeStringFromMap(bindingInfos));
                             }
                         }
                     }
@@ -1491,7 +1491,7 @@ public class DataBindingPage extends Page implements IBindingDataSetListener {
             String propertyValue =
                     part.getProperty(BuilderConstants.ATTRIBUTE_DATA_BIND).getValue();
             if ((propertyValue != null) && (!propertyValue.isEmpty())) {
-                Map<String, String> bindingInfos = DataBindingTooltipParser.parseToMap(propertyValue);
+                Map<String, String> bindingInfos = DataBindingHelper.parseToMap(propertyValue);
                 Object[] bindingTypes = bindingInfos.keySet().toArray();
                 for (Object bindingType : bindingTypes) {
                     String value = bindingInfos.get(bindingType);
@@ -1499,7 +1499,7 @@ public class DataBindingPage extends Page implements IBindingDataSetListener {
                         value = value.replace(oldValue, newValue);
                         bindingInfos.remove(bindingType.toString());
                         bindingInfos.put(bindingType.toString(), value);
-                        String bindingInfo = DataBindingTooltipParser.makeStringFromMap(bindingInfos);
+                        String bindingInfo = DataBindingHelper.makeStringFromMap(bindingInfos);
                         part.setPropertyValue(BuilderConstants.ATTRIBUTE_DATA_BIND, bindingInfo);
                     }
                 }
index ac66e47..8dd7c02 100644 (file)
@@ -32,7 +32,7 @@ import org.eclipse.ui.PlatformUI;
 import org.eclipse.ui.part.IPage;
 import org.tizen.webuibuilder.model.Part;
 import org.tizen.webuibuilder.ui.views.databinding.DataBindingPage;
-import org.tizen.webuibuilder.ui.views.databinding.DataBindingTooltipParser;
+import org.tizen.webuibuilder.ui.views.databinding.DataBindingHelper;
 import org.tizen.webuibuilder.ui.views.databinding.DataBindingView;
 import org.tizen.webuibuilder.ui.views.databinding.dialog.SetTargetPage;
 import org.tizen.webuibuilder.ui.views.databinding.model.BindingInfo;
@@ -119,7 +119,7 @@ public class SetTargetAction extends SelectionAction {
         String infoValue = bindingInfo.getInfoValue();
         String infoDisplayName = bindingInfo.getInfoDisplayName();
         
-        String viewModelInfo = DataBindingTooltipParser.makeViewModelInfo(treeItem);
+        String viewModelInfo = DataBindingHelper.makeViewModelInfo(treeItem);
         
         if (targetPart != null) {
             dataBindingPage.setBindingInfoToPart(targetPart, viewModelInfo, infoDisplayName, infoValue);
index a4b6594..9d109b8 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding.model;
 
 
index 961cf67..ca54787 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding.model;
 
 import org.tizen.webuibuilder.model.Part;
index e44e9d1..a3263f3 100644 (file)
@@ -1,4 +1,24 @@
-
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding.model;
 
index 624156f..9859b69 100644 (file)
@@ -1,3 +1,25 @@
+/*
+ * UI Builder
+ *
+ * Copyright (c) 2000 - 2014 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * 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.webuibuilder.ui.views.databinding.model;
 
 import java.util.EventListener;