Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorspingel2009-11-18 22:28:58 -0500
committerspingel2009-11-18 22:28:58 -0500
commitbed92deb293917c1c7f389eb66a6d61c0e14cf00 (patch)
treead0257a08c316c1b8fae93c28eac43b799a7ace3 /org.eclipse.mylyn.tasks.core
parent449f183c7d5f4f6b7a8c224db89a202520817f9e (diff)
downloadorg.eclipse.mylyn.tasks-bed92deb293917c1c7f389eb66a6d61c0e14cf00.tar.gz
org.eclipse.mylyn.tasks-bed92deb293917c1c7f389eb66a6d61c0e14cf00.tar.xz
org.eclipse.mylyn.tasks-bed92deb293917c1c7f389eb66a6d61c0e14cf00.zip
RESOLVED - bug 247595: extend TaskMapper with default schema
https://bugs.eclipse.org/bugs/show_bug.cgi?id=247595
Diffstat (limited to 'org.eclipse.mylyn.tasks.core')
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/DefaultTaskSchema.java74
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/Messages.java85
-rw-r--r--org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/messages.properties30
3 files changed, 152 insertions, 37 deletions
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/DefaultTaskSchema.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/DefaultTaskSchema.java
index 524a11b59..28b851c6b 100644
--- a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/DefaultTaskSchema.java
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/DefaultTaskSchema.java
@@ -120,111 +120,111 @@ public class DefaultTaskSchema {
return fieldByKey.get(taskKey);
}
- public static final Field ADD_SELF_CC = createField(TaskAttribute.ADD_SELF_CC, "Add Self to CC",
+ public static final Field ADD_SELF_CC = createField(TaskAttribute.ADD_SELF_CC, Messages.DefaultTaskSchema_Add_Self_to_CC_Label,
TaskAttribute.TYPE_BOOLEAN);
- public static final Field ATTACHMENT_AUTHOR = createField(TaskAttribute.ATTACHMENT_AUTHOR, "Author",
+ public static final Field ATTACHMENT_AUTHOR = createField(TaskAttribute.ATTACHMENT_AUTHOR, Messages.DefaultTaskSchema_Author_Label,
TaskAttribute.TYPE_PERSON);
public static final Field ATTACHMENT_CONTENT_TYPE = createField(TaskAttribute.ATTACHMENT_CONTENT_TYPE,
- "Content-Type", TaskAttribute.TYPE_SHORT_TEXT);
+ Messages.DefaultTaskSchema_Content_Type_Label, TaskAttribute.TYPE_SHORT_TEXT);
- public static final Field ATTACHMENT_DATE = createField(TaskAttribute.ATTACHMENT_DATE, "Created",
+ public static final Field ATTACHMENT_DATE = createField(TaskAttribute.ATTACHMENT_DATE, Messages.DefaultTaskSchema_Created_Label,
TaskAttribute.TYPE_DATETIME);
- public static final Field ATTACHMENT_DESCRIPTION = createField(TaskAttribute.ATTACHMENT_DESCRIPTION, "Description",
+ public static final Field ATTACHMENT_DESCRIPTION = createField(TaskAttribute.ATTACHMENT_DESCRIPTION, Messages.DefaultTaskSchema_Description_Label,
TaskAttribute.TYPE_SHORT_RICH_TEXT);
- public static final Field ATTACHMENT_FILENAME = createField(TaskAttribute.ATTACHMENT_FILENAME, "Filename",
+ public static final Field ATTACHMENT_FILENAME = createField(TaskAttribute.ATTACHMENT_FILENAME, Messages.DefaultTaskSchema_Filename_Label,
TaskAttribute.TYPE_SHORT_TEXT);
- public static final Field ATTACHMENT_ID = createField(TaskAttribute.ATTACHMENT_ID, "ID",
+ public static final Field ATTACHMENT_ID = createField(TaskAttribute.ATTACHMENT_ID, Messages.DefaultTaskSchema_ID_Label,
TaskAttribute.TYPE_SHORT_TEXT, Flag.READ_ONLY);
public static final Field ATTACHMENT_IS_DEPRECATED = createField(TaskAttribute.ATTACHMENT_IS_DEPRECATED,
- "Deprecated", TaskAttribute.TYPE_BOOLEAN);
+ Messages.DefaultTaskSchema_Deprecated_Label, TaskAttribute.TYPE_BOOLEAN);
- public static final Field ATTACHMENT_IS_PATCH = createField(TaskAttribute.ATTACHMENT_IS_PATCH, "Patch",
+ public static final Field ATTACHMENT_IS_PATCH = createField(TaskAttribute.ATTACHMENT_IS_PATCH, Messages.DefaultTaskSchema_Patch_Label,
TaskAttribute.TYPE_BOOLEAN);
- public static final Field ATTACHMENT_SIZE = createField(TaskAttribute.ATTACHMENT_SIZE, "Size",
+ public static final Field ATTACHMENT_SIZE = createField(TaskAttribute.ATTACHMENT_SIZE, Messages.DefaultTaskSchema_Size_Label,
TaskAttribute.TYPE_LONG, Flag.READ_ONLY);
- public static final Field ATTACHMENT_URL = createField(TaskAttribute.ATTACHMENT_URL, "URL", TaskAttribute.TYPE_URL);
+ public static final Field ATTACHMENT_URL = createField(TaskAttribute.ATTACHMENT_URL, Messages.DefaultTaskSchema_URL_Label, TaskAttribute.TYPE_URL);
- public static final Field COMMENT_ATTACHMENT_ID = createField(TaskAttribute.COMMENT_ATTACHMENT_ID, "Attachment ID",
+ public static final Field COMMENT_ATTACHMENT_ID = createField(TaskAttribute.COMMENT_ATTACHMENT_ID, Messages.DefaultTaskSchema_Attachment_ID_Label,
TaskAttribute.TYPE_SHORT_TEXT, Flag.READ_ONLY);
- public static final Field COMMENT_AUTHOR = createField(TaskAttribute.COMMENT_AUTHOR, "Author",
+ public static final Field COMMENT_AUTHOR = createField(TaskAttribute.COMMENT_AUTHOR, Messages.DefaultTaskSchema_Author_Label,
TaskAttribute.TYPE_PERSON);
- public static final Field COMMENT_DATE = createField(TaskAttribute.COMMENT_DATE, "Created",
+ public static final Field COMMENT_DATE = createField(TaskAttribute.COMMENT_DATE, Messages.DefaultTaskSchema_Created_Label,
TaskAttribute.TYPE_DATETIME);
- public static final Field COMMENT_HAS_ATTACHMENT = createField(TaskAttribute.COMMENT_HAS_ATTACHMENT, "Attachment",
+ public static final Field COMMENT_HAS_ATTACHMENT = createField(TaskAttribute.COMMENT_HAS_ATTACHMENT, Messages.DefaultTaskSchema_Attachment_Label,
TaskAttribute.TYPE_BOOLEAN);
- public static final Field COMMENT_NUMBER = createField(TaskAttribute.COMMENT_NUMBER, "Number",
+ public static final Field COMMENT_NUMBER = createField(TaskAttribute.COMMENT_NUMBER, Messages.DefaultTaskSchema_Number_Label,
TaskAttribute.TYPE_INTEGER, Flag.READ_ONLY);
- public static final Field COMMENT_TEXT = createField(TaskAttribute.COMMENT_TEXT, "Description",
+ public static final Field COMMENT_TEXT = createField(TaskAttribute.COMMENT_TEXT, Messages.DefaultTaskSchema_Description_Label,
TaskAttribute.TYPE_LONG_RICH_TEXT);
- public static final Field COMMENT_URL = createField(TaskAttribute.COMMENT_URL, "URL", TaskAttribute.TYPE_URL);
+ public static final Field COMMENT_URL = createField(TaskAttribute.COMMENT_URL, Messages.DefaultTaskSchema_URL_Label, TaskAttribute.TYPE_URL);
- public static final Field COMPONENT = createField(TaskAttribute.COMPONENT, "Component",
+ public static final Field COMPONENT = createField(TaskAttribute.COMPONENT, Messages.DefaultTaskSchema_Component_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.ATTRIBUTE);
- public static final Field DATE_COMPLETION = createField(TaskAttribute.DATE_COMPLETION, "Completion",
+ public static final Field DATE_COMPLETION = createField(TaskAttribute.DATE_COMPLETION, Messages.DefaultTaskSchema_Completion_Label,
TaskAttribute.TYPE_DATE, Flag.READ_ONLY);
- public static final Field DATE_CREATION = createField(TaskAttribute.DATE_CREATION, "Created",
+ public static final Field DATE_CREATION = createField(TaskAttribute.DATE_CREATION, Messages.DefaultTaskSchema_Created_Label,
TaskAttribute.TYPE_DATE, Flag.READ_ONLY);
- public static final Field DATE_DUE = createField(TaskAttribute.DATE_DUE, "Due", TaskAttribute.TYPE_DATE);
+ public static final Field DATE_DUE = createField(TaskAttribute.DATE_DUE, Messages.DefaultTaskSchema_Due_Label, TaskAttribute.TYPE_DATE);
- public static final Field DATE_MODIFICATION = createField(TaskAttribute.DATE_MODIFICATION, "Modified",
+ public static final Field DATE_MODIFICATION = createField(TaskAttribute.DATE_MODIFICATION, Messages.DefaultTaskSchema_Modified_Label,
TaskAttribute.TYPE_DATE, Flag.READ_ONLY);
- public static final Field DESCRIPTION = createField(TaskAttribute.DESCRIPTION, "Description",
+ public static final Field DESCRIPTION = createField(TaskAttribute.DESCRIPTION, Messages.DefaultTaskSchema_Description_Label,
TaskAttribute.TYPE_LONG_RICH_TEXT);
- public static final Field KEYWORDS = createField(TaskAttribute.KEYWORDS, "Keywords",
+ public static final Field KEYWORDS = createField(TaskAttribute.KEYWORDS, Messages.DefaultTaskSchema_Keywords_Label,
TaskAttribute.TYPE_MULTI_SELECT, Flag.ATTRIBUTE);
- public static final Field PRIORITY = createField(TaskAttribute.PRIORITY, "Priority",
+ public static final Field PRIORITY = createField(TaskAttribute.PRIORITY, Messages.DefaultTaskSchema_Priority_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.ATTRIBUTE);
- public static final Field PRODUCT = createField(TaskAttribute.PRIORITY, "Product",
+ public static final Field PRODUCT = createField(TaskAttribute.PRIORITY, Messages.DefaultTaskSchema_Product_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.ATTRIBUTE);
- public static final Field RANK = createField(TaskAttribute.RANK, "Rank", TaskAttribute.TYPE_INTEGER, Flag.READ_ONLY);
+ public static final Field RANK = createField(TaskAttribute.RANK, Messages.DefaultTaskSchema_Rank_Label, TaskAttribute.TYPE_INTEGER, Flag.READ_ONLY);
- public static final Field RESOLUTION = createField(TaskAttribute.RESOLUTION, "Resolution",
+ public static final Field RESOLUTION = createField(TaskAttribute.RESOLUTION, Messages.DefaultTaskSchema_Resolution_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.READ_ONLY);
- public static final Field SEVERITY = createField(TaskAttribute.SEVERITY, "Severity",
+ public static final Field SEVERITY = createField(TaskAttribute.SEVERITY, Messages.DefaultTaskSchema_Severity_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.ATTRIBUTE);
- public static final Field STATUS = createField(TaskAttribute.STATUS, "Status", TaskAttribute.TYPE_SHORT_TEXT,
+ public static final Field STATUS = createField(TaskAttribute.STATUS, Messages.DefaultTaskSchema_Status_Label, TaskAttribute.TYPE_SHORT_TEXT,
Flag.READ_ONLY);
- public static final Field SUMMARY = createField(TaskAttribute.SUMMARY, "Summary",
+ public static final Field SUMMARY = createField(TaskAttribute.SUMMARY, Messages.DefaultTaskSchema_Summary_Label,
TaskAttribute.TYPE_SHORT_RICH_TEXT);
- public static final Field TASK_KEY = createField(TaskAttribute.TASK_KEY, "Key", TaskAttribute.TYPE_SHORT_TEXT,
+ public static final Field TASK_KEY = createField(TaskAttribute.TASK_KEY, Messages.DefaultTaskSchema_Key_Label, TaskAttribute.TYPE_SHORT_TEXT,
Flag.READ_ONLY);
- public static final Field TASK_KIND = createField(TaskAttribute.TASK_KIND, "Kind",
+ public static final Field TASK_KIND = createField(TaskAttribute.TASK_KIND, Messages.DefaultTaskSchema_Kind_Label,
TaskAttribute.TYPE_SINGLE_SELECT, Flag.ATTRIBUTE);
- public static final Field USER_ASSIGNED = createField(TaskAttribute.USER_ASSIGNED, "Owner",
+ public static final Field USER_ASSIGNED = createField(TaskAttribute.USER_ASSIGNED, Messages.DefaultTaskSchema_Owner_Label,
TaskAttribute.TYPE_PERSON, Flag.PEOPLE);
- public static final Field USER_REPORTER = createField(TaskAttribute.USER_REPORTER, "Reporter",
+ public static final Field USER_REPORTER = createField(TaskAttribute.USER_REPORTER, Messages.DefaultTaskSchema_Reporter_Label,
TaskAttribute.TYPE_PERSON, Flag.PEOPLE);
- public static final Field TASK_URL = createField(TaskAttribute.TASK_URL, "URL", TaskAttribute.TYPE_URL,
+ public static final Field TASK_URL = createField(TaskAttribute.TASK_URL, Messages.DefaultTaskSchema_URL_Label, TaskAttribute.TYPE_URL,
Flag.READ_ONLY);
private static Field createField(String key, String label, String type) {
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/Messages.java b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/Messages.java
new file mode 100644
index 000000000..4e68e4f4a
--- /dev/null
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/Messages.java
@@ -0,0 +1,85 @@
+/*******************************************************************************
+ * Copyright (c) 2009 Tasktop Technologies and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Tasktop Technologies - initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.mylyn.internal.tasks.core.data;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.eclipse.mylyn.internal.tasks.core.data.messages"; //$NON-NLS-1$
+
+ public static String DefaultTaskSchema_Add_Self_to_CC_Label;
+
+ public static String DefaultTaskSchema_Attachment_ID_Label;
+
+ public static String DefaultTaskSchema_Attachment_Label;
+
+ public static String DefaultTaskSchema_Author_Label;
+
+ public static String DefaultTaskSchema_Completion_Label;
+
+ public static String DefaultTaskSchema_Component_Label;
+
+ public static String DefaultTaskSchema_Content_Type_Label;
+
+ public static String DefaultTaskSchema_Created_Label;
+
+ public static String DefaultTaskSchema_Deprecated_Label;
+
+ public static String DefaultTaskSchema_Description_Label;
+
+ public static String DefaultTaskSchema_Due_Label;
+
+ public static String DefaultTaskSchema_Filename_Label;
+
+ public static String DefaultTaskSchema_ID_Label;
+
+ public static String DefaultTaskSchema_Key_Label;
+
+ public static String DefaultTaskSchema_Keywords_Label;
+
+ public static String DefaultTaskSchema_Kind_Label;
+
+ public static String DefaultTaskSchema_Modified_Label;
+
+ public static String DefaultTaskSchema_Number_Label;
+
+ public static String DefaultTaskSchema_Owner_Label;
+
+ public static String DefaultTaskSchema_Patch_Label;
+
+ public static String DefaultTaskSchema_Priority_Label;
+
+ public static String DefaultTaskSchema_Product_Label;
+
+ public static String DefaultTaskSchema_Rank_Label;
+
+ public static String DefaultTaskSchema_Reporter_Label;
+
+ public static String DefaultTaskSchema_Resolution_Label;
+
+ public static String DefaultTaskSchema_Severity_Label;
+
+ public static String DefaultTaskSchema_Size_Label;
+
+ public static String DefaultTaskSchema_Status_Label;
+
+ public static String DefaultTaskSchema_Summary_Label;
+
+ public static String DefaultTaskSchema_URL_Label;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
diff --git a/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/messages.properties b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/messages.properties
new file mode 100644
index 000000000..a33bae106
--- /dev/null
+++ b/org.eclipse.mylyn.tasks.core/src/org/eclipse/mylyn/internal/tasks/core/data/messages.properties
@@ -0,0 +1,30 @@
+DefaultTaskSchema_Add_Self_to_CC_Label=Add Self to CC
+DefaultTaskSchema_Attachment_ID_Label=Attachment ID
+DefaultTaskSchema_Attachment_Label=Attachment
+DefaultTaskSchema_Author_Label=Author
+DefaultTaskSchema_Completion_Label=Completion
+DefaultTaskSchema_Component_Label=Component
+DefaultTaskSchema_Content_Type_Label=Content-Type
+DefaultTaskSchema_Created_Label=Created
+DefaultTaskSchema_Deprecated_Label=Deprecated
+DefaultTaskSchema_Description_Label=Description
+DefaultTaskSchema_Due_Label=Due
+DefaultTaskSchema_Filename_Label=Filename
+DefaultTaskSchema_ID_Label=ID
+DefaultTaskSchema_Key_Label=Key
+DefaultTaskSchema_Keywords_Label=Keywords
+DefaultTaskSchema_Kind_Label=Kind
+DefaultTaskSchema_Modified_Label=Modified
+DefaultTaskSchema_Number_Label=Number
+DefaultTaskSchema_Owner_Label=Owner
+DefaultTaskSchema_Patch_Label=Patch
+DefaultTaskSchema_Priority_Label=Priority
+DefaultTaskSchema_Product_Label=Product
+DefaultTaskSchema_Rank_Label=Rank
+DefaultTaskSchema_Reporter_Label=Reporter
+DefaultTaskSchema_Resolution_Label=Resolution
+DefaultTaskSchema_Severity_Label=Severity
+DefaultTaskSchema_Size_Label=Size
+DefaultTaskSchema_Status_Label=Status
+DefaultTaskSchema_Summary_Label=Summary
+DefaultTaskSchema_URL_Label=URL

Back to the top