diff options
author | Eike Stepper | 2012-05-25 09:33:40 +0000 |
---|---|---|
committer | Eike Stepper | 2012-05-25 09:33:40 +0000 |
commit | 3b2739c54db63f060472c2172f81312225220d9e (patch) | |
tree | e45ded7d3854123c3f6be76ead461a8f6158fbb0 | |
parent | 5d3e0af4e24dc25c08fbccd491bd5deed675213d (diff) | |
download | cdo-3b2739c54db63f060472c2172f81312225220d9e.tar.gz cdo-3b2739c54db63f060472c2172f81312225220d9e.tar.xz cdo-3b2739c54db63f060472c2172f81312225220d9e.zip |
[380629] Design a default Security model
https://bugs.eclipse.org/bugs/show_bug.cgi?id=380629
105 files changed, 12608 insertions, 29 deletions
diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.classpath b/plugins/org.eclipse.emf.cdo.security.edit/.classpath new file mode 100644 index 0000000000..304e86186a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.classpath @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<classpath> + <classpathentry kind="src" path="src"/> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/> + <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> + <classpathentry kind="output" path="bin"/> +</classpath> diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.project b/plugins/org.eclipse.emf.cdo.security.edit/.project new file mode 100644 index 0000000000..dee66d200a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.project @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.emf.cdo.security.edit</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.ManifestBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.SchemaBuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>org.eclipse.pde.PluginNature</nature> + </natures> +</projectDescription> diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 0000000000..8085bb7dc7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,4 @@ +eclipse.preferences.version=1 +encoding//model/org.eclipse.emf.cdo.defs.ecorediag=UTF-8 +encoding//model/security.ecore=UTF-8 +encoding//model/security.ecorediag=UTF-8 diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..2b35acc859 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,413 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.cleanOutputFolder=clean +org.eclipse.jdt.core.builder.duplicateResourceTask=warning +org.eclipse.jdt.core.builder.invalidClasspath=abort +org.eclipse.jdt.core.builder.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch,*.ucls,doc-files/,package.html,package-info.java +org.eclipse.jdt.core.circularClasspath=error +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.codeComplete.argumentPrefixes= +org.eclipse.jdt.core.codeComplete.argumentSuffixes= +org.eclipse.jdt.core.codeComplete.fieldPrefixes= +org.eclipse.jdt.core.codeComplete.fieldSuffixes= +org.eclipse.jdt.core.codeComplete.localPrefixes= +org.eclipse.jdt.core.codeComplete.localSuffixes= +org.eclipse.jdt.core.codeComplete.staticFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFieldSuffixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes= +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault +org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable +org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.5 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.doc.comment.support=enabled +org.eclipse.jdt.core.compiler.maxProblemPerUnit=100 +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=warning +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore +org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=warning +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning +org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=warning +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.source=1.5 +org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled +org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,HIGH,LOW,LOW,LOW,LOW,LOW +org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,PERF,MEM,POLISH,@generated NOT,@ADDED +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 +org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=1 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 +org.eclipse.jdt.core.formatter.blank_lines_before_method=1 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 +org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=next_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=next_line +org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=next_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=next_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=true +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=true +org.eclipse.jdt.core.formatter.comment.format_block_comments=true +org.eclipse.jdt.core.formatter.comment.format_header=false +org.eclipse.jdt.core.formatter.comment.format_html=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false +org.eclipse.jdt.core.formatter.comment.format_line_comments=true +org.eclipse.jdt.core.formatter.comment.format_source_code=true +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true +org.eclipse.jdt.core.formatter.comment.indent_root_tags=true +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert +org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert +org.eclipse.jdt.core.formatter.comment.line_length=120 +org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true +org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true +org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off +org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false +org.eclipse.jdt.core.formatter.indentation.size=2 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_member=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.join_lines_in_comments=true +org.eclipse.jdt.core.formatter.join_wrapped_lines=true +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.formatter.lineSplit=120 +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true +org.eclipse.jdt.core.formatter.tabulation.char=space +org.eclipse.jdt.core.formatter.tabulation.size=2 +org.eclipse.jdt.core.formatter.use_on_off_tags=false +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=ignore +org.eclipse.jdt.core.incompleteClasspath=error diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.launching.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.launching.prefs new file mode 100644 index 0000000000..556ed07a3c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.launching.prefs @@ -0,0 +1,3 @@ +#Fri Sep 02 05:38:34 CEST 2011 +eclipse.preferences.version=1 +org.eclipse.jdt.launching.PREF_STRICTLY_COMPATIBLE_JRE_NOT_AVAILABLE=ignore diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.ui.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 0000000000..4343e2f963 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,119 @@ +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.always_use_blocks=true +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.convert_to_enhanced_for_loop=false +cleanup.correct_indentation=true +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=false +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=false +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.organize_imports=true +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.remove_private_constructors=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_private_fields=true +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=true +cleanup.remove_unused_private_types=true +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.use_blocks=true +cleanup.use_blocks_only_for_return_and_throw=false +cleanup.use_parentheses_in_expressions=true +cleanup.use_this_for_non_static_field_access=true +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=true +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup_profile=_EMFT +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_EMFT +formatter_settings_version=12 +org.eclipse.jdt.ui.exception.name=ex +org.eclipse.jdt.ui.gettersetter.use.is=true +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=org.eclipse.emf.cdo;org.eclipse.emf.internal.cdo;org.eclipse.net4j;org.eclipse.internal.net4j;org.eclipse.emf;org.eclipse;com;org;javax;java; +org.eclipse.jdt.ui.javadoc=true +org.eclipse.jdt.ui.keywordthis=false +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.overrideannotation=true +org.eclipse.jdt.ui.staticondemandthreshold=99 +org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="false" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment"/><template autoinsert\="false" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment"/><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment"/><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\r\n * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) and others.\r\n * All rights reserved. This program and the accompanying materials\r\n * are made available under the terms of the Eclipse Public License v1.0\r\n * which accompanies this distribution, and is available at\r\n * http\://www.eclipse.org/legal/epl-v10.html\r\n * \r\n * Contributors\:\r\n * Eike Stepper - initial API and implementation\r\n */</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\r\n * @author Eike Stepper\r\n */</template><template autoinsert\="false" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment"/><template autoinsert\="false" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment"/><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment"/><template autoinsert\="false" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment"/><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\r\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\r\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\r\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\r\n</template><template autoinsert\="false" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">${exception_var}.printStackTrace();</template><template autoinsert\="false" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">${body_statement}</template><template autoinsert\="false" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates> +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=false +sp_cleanup.add_serial_version_id=false +sp_cleanup.always_use_blocks=true +sp_cleanup.always_use_parentheses_in_expressions=false +sp_cleanup.always_use_this_for_non_static_field_access=false +sp_cleanup.always_use_this_for_non_static_method_access=false +sp_cleanup.convert_to_enhanced_for_loop=false +sp_cleanup.correct_indentation=true +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.make_local_variable_final=false +sp_cleanup.make_parameters_final=false +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=false +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.organize_imports=true +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.remove_private_constructors=true +sp_cleanup.remove_trailing_whitespaces=true +sp_cleanup.remove_trailing_whitespaces_all=true +sp_cleanup.remove_trailing_whitespaces_ignore_empty=false +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_private_fields=true +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=true +sp_cleanup.remove_unused_private_types=true +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.use_blocks=true +sp_cleanup.use_blocks_only_for_return_and_throw=false +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_this_for_non_static_field_access=true +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=true +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.ltk.core.refactoring.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.ltk.core.refactoring.prefs new file mode 100644 index 0000000000..864e30fe5d --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.ltk.core.refactoring.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +org.eclipse.ltk.core.refactoring.enable.project.refactoring.history=false diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.tasks.ui.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.tasks.ui.prefs new file mode 100644 index 0000000000..b050639a54 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.tasks.ui.prefs @@ -0,0 +1,4 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +project.repository.kind=bugzilla +project.repository.url=https\://bugs.eclipse.org/bugs diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.team.ui.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.team.ui.prefs new file mode 100644 index 0000000000..2f50f36c0c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.mylyn.team.ui.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +commit.comment.template=[${task.id}] ${task.description} \r\n${task.url} +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.api.tools.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.api.tools.prefs new file mode 100644 index 0000000000..f8d0a0660e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.api.tools.prefs @@ -0,0 +1,94 @@ +#Thu Feb 04 09:44:24 CET 2010 +ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error +ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error +CLASS_ELEMENT_TYPE_ADDED_METHOD=Error +CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error +CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error +CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error +CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error +ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error +ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error +ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +FIELD_ELEMENT_TYPE_ADDED_VALUE=Error +FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error +FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error +FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error +FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error +ILLEGAL_EXTEND=Warning +ILLEGAL_IMPLEMENT=Warning +ILLEGAL_INSTANTIATE=Warning +ILLEGAL_OVERRIDE=Warning +ILLEGAL_REFERENCE=Warning +INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error +INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error +INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error +INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +INVALID_JAVADOC_TAG=Ignore +INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Ignore +LEAK_EXTEND=Warning +LEAK_FIELD_DECL=Warning +LEAK_IMPLEMENT=Warning +LEAK_METHOD_PARAM=Warning +LEAK_METHOD_RETURN_TYPE=Warning +METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error +METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error +UNUSED_PROBLEM_FILTERS=Ignore +automatically_removed_unused_problem_filters=Disabled +eclipse.preferences.version=1 +incompatible_api_component_version=Error +incompatible_api_component_version_include_major_without_breaking_change=Disabled +incompatible_api_component_version_include_minor_without_api_change=Disabled +invalid_since_tag_version=Error +malformed_since_tag=Error +missing_since_tag=Error +report_api_breakage_when_major_version_incremented=Disabled +report_resolution_errors_api_component=Warning diff --git a/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.prefs b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.prefs new file mode 100644 index 0000000000..c6b96bb45e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/.settings/org.eclipse.pde.prefs @@ -0,0 +1,31 @@ +#Thu Feb 04 09:44:24 CET 2010 +compilers.f.unresolved-features=1 +compilers.f.unresolved-plugins=1 +compilers.incompatible-environment=1 +compilers.p.build=1 +compilers.p.build.bin.includes=1 +compilers.p.build.java.compliance=1 +compilers.p.build.missing.output=2 +compilers.p.build.output.library=1 +compilers.p.build.source.library=1 +compilers.p.build.src.includes=1 +compilers.p.deprecated=1 +compilers.p.discouraged-class=1 +compilers.p.internal=1 +compilers.p.missing-packages=1 +compilers.p.missing-version-export-package=1 +compilers.p.missing-version-import-package=1 +compilers.p.missing-version-require-bundle=1 +compilers.p.no-required-att=0 +compilers.p.not-externalized-att=2 +compilers.p.unknown-attribute=1 +compilers.p.unknown-class=1 +compilers.p.unknown-element=1 +compilers.p.unknown-identifier=1 +compilers.p.unknown-resource=1 +compilers.p.unresolved-ex-points=0 +compilers.p.unresolved-import=0 +compilers.s.create-docs=false +compilers.s.doc-folder=doc +compilers.s.open-tags=1 +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security.edit/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.cdo.security.edit/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..aae2f28701 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/META-INF/MANIFEST.MF @@ -0,0 +1,15 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: %pluginName +Bundle-SymbolicName: org.eclipse.emf.cdo.security.edit;singleton:=true +Bundle-Version: 4.1.0.qualifier +Bundle-ClassPath: . +Bundle-Activator: org.eclipse.emf.cdo.security.provider.SecurityEditPlugin$Implementation +Bundle-Vendor: %providerName +Bundle-Localization: plugin +Bundle-RequiredExecutionEnvironment: J2SE-1.5 +Export-Package: org.eclipse.emf.cdo.security.provider;version="4.1.0" +Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.4.0,4.0.0)", + org.eclipse.emf.cdo.security;bundle-version="[4.1.0,5.0.0)";visibility:=reexport, + org.eclipse.emf.cdo.edit;bundle-version="[4.1.0,5.0.0)";visibility:=reexport +Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.cdo.security.edit/about.html b/plugins/org.eclipse.emf.cdo.security.edit/about.html new file mode 100644 index 0000000000..d35d5aed64 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 5, 2007</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise +indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html> diff --git a/plugins/org.eclipse.emf.cdo.security.edit/build.properties b/plugins/org.eclipse.emf.cdo.security.edit/build.properties new file mode 100644 index 0000000000..29cb0969dd --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/build.properties @@ -0,0 +1,14 @@ +# + +bin.includes = .,\ + icons/,\ + META-INF/,\ + plugin.xml,\ + plugin.properties,\ + about.html,\ + copyright.txt +jars.compile.order = . +source.. = src/ +output.. = bin/ +src.includes = about.html,\ + copyright.txt diff --git a/plugins/org.eclipse.emf.cdo.security.edit/copyright.txt b/plugins/org.eclipse.emf.cdo.security.edit/copyright.txt new file mode 100644 index 0000000000..0a0f67e6d7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/copyright.txt @@ -0,0 +1,8 @@ +Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation
\ No newline at end of file diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Container.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Container.gif Binary files differnew file mode 100644 index 0000000000..c00aedf413 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Container.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Directory.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Directory.gif Binary files differnew file mode 100644 index 0000000000..134551bff7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Directory.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Group.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Group.gif Binary files differnew file mode 100644 index 0000000000..90d10f9470 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Group.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Realm.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Realm.gif Binary files differnew file mode 100644 index 0000000000..33a997a160 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Realm.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Role.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Role.gif Binary files differnew file mode 100644 index 0000000000..be22463d29 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/Role.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/SecurityRealm.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/SecurityRealm.gif Binary files differnew file mode 100644 index 0000000000..14af8aaee9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/SecurityRealm.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/User.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/User.gif Binary files differnew file mode 100644 index 0000000000..48e3cf2268 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/User.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/UserPassword.gif b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/UserPassword.gif Binary files differnew file mode 100644 index 0000000000..2124f3e3ab --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/icons/full/obj16/UserPassword.gif diff --git a/plugins/org.eclipse.emf.cdo.security.edit/plugin.properties b/plugins/org.eclipse.emf.cdo.security.edit/plugin.properties new file mode 100644 index 0000000000..beaad9d7aa --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/plugin.properties @@ -0,0 +1,61 @@ +# Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: +# Eike Stepper - initial API and implementation + +pluginName = CDO Model Repository Security Edit Support +providerName = Eclipse Modeling Project + +_UI_CreateChild_text = {0} +_UI_CreateChild_text2 = {1} {0} +_UI_CreateChild_text3 = {1} +_UI_CreateChild_tooltip = Create New {0} Under {1} Feature +_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. +_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. + +_UI_PropertyDescriptor_description = The {0} of the {1} + +_UI_SecurityElement_type = Element +_UI_SecurityRealm_type = Realm +_UI_SecurityItem_type = Item +_UI_Container_type = Container +_UI_Role_type = Role +_UI_Assignee_type = Assignee +_UI_Group_type = Group +_UI_User_type = User +_UI_UserPassword_type = Password +_UI_Unknown_type = Object + +_UI_Unknown_datatype= Value + +_UI_SecurityRealm_items_feature = Items +_UI_SecurityRealm_name_feature = Name +_UI_Container_items_feature = Items +_UI_Container_name_feature = Name +_UI_Role_assignees_feature = Assignees +_UI_Role_id_feature = Id +_UI_Role_type_feature = Type +_UI_Assignee_roles_feature = Roles +_UI_Assignee_id_feature = Id +_UI_Group_users_feature = Users +_UI_User_groups_feature = Groups +_UI_User_firstName_feature = First Name +_UI_User_lastName_feature = Last Name +_UI_User_email_feature = Email +_UI_User_locked_feature = Locked +_UI_User_password_feature = Password +_UI_UserPassword_encrypted_feature = Encrypted +_UI_Unknown_feature = Unspecified + +_UI_Realm_type = Realm +_UI_Realm_items_feature = Items +_UI_Realm_name_feature = Name +_UI_Group_inheritedGroups_feature = Inherited Groups +_UI_Group_inheritingGroups_feature = Inheriting Groups +_UI_Directory_type = Directory +_UI_Directory_items_feature = Items +_UI_Directory_name_feature = Name diff --git a/plugins/org.eclipse.emf.cdo.security.edit/plugin.xml b/plugins/org.eclipse.emf.cdo.security.edit/plugin.xml new file mode 100644 index 0000000000..9543baf0b1 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/plugin.xml @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?eclipse version="3.4"?> +<!-- + Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation +--> + +<plugin> + + <extension point="org.eclipse.emf.edit.itemProviderAdapterFactories"> + <factory + uri="http://www.eclipse.org/emf/CDO/security/4.1.0" + class="org.eclipse.emf.cdo.security.provider.SecurityItemProviderAdapterFactory" + supportedTypes= + "org.eclipse.emf.edit.provider.IEditingDomainItemProvider + org.eclipse.emf.edit.provider.IStructuredItemContentProvider + org.eclipse.emf.edit.provider.ITreeItemContentProvider + org.eclipse.emf.edit.provider.IItemLabelProvider + org.eclipse.emf.edit.provider.IItemPropertySource + org.eclipse.emf.edit.provider.ITableItemLabelProvider + org.eclipse.emf.edit.provider.ITableItemColorProvider + org.eclipse.emf.edit.provider.ITableItemFontProvider + org.eclipse.emf.edit.provider.IItemColorProvider + org.eclipse.emf.edit.provider.IItemFontProvider"/> + </extension> + +</plugin> diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/AssigneeItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/AssigneeItemProvider.java new file mode 100644 index 0000000000..194ee7fc5c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/AssigneeItemProvider.java @@ -0,0 +1,167 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.Assignee} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class AssigneeItemProvider extends SecurityItemItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public AssigneeItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addRolesPropertyDescriptor(object); + addIdPropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Roles feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addRolesPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Assignee_roles_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Assignee_roles_feature", "_UI_Assignee_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.ASSIGNEE__ROLES, true, false, true, null, null, null)); + } + + /** + * This adds a property descriptor for the Id feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addIdPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Assignee_id_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Assignee_id_feature", "_UI_Assignee_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.ASSIGNEE__ID, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((Assignee)object).getId(); + return label == null || label.length() == 0 ? getString("_UI_Assignee_type") : //$NON-NLS-1$ + getString("_UI_Assignee_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(Assignee.class)) + { + case SecurityPackage.ASSIGNEE__ID: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/DirectoryItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/DirectoryItemProvider.java new file mode 100644 index 0000000000..26b6761698 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/DirectoryItemProvider.java @@ -0,0 +1,213 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.Directory} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class DirectoryItemProvider extends SecurityItemItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public DirectoryItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addNamePropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addNamePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Directory_name_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Directory_name_feature", "_UI_Directory_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.DIRECTORY__NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an + * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or + * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) + { + if (childrenFeatures == null) + { + super.getChildrenFeatures(object); + childrenFeatures.add(SecurityPackage.Literals.DIRECTORY__ITEMS); + } + return childrenFeatures; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EStructuralFeature getChildFeature(Object object, Object child) + { + // Check the type of the specified child object and return the proper feature to use for + // adding (see {@link AddCommand}) it as a child. + + return super.getChildFeature(object, child); + } + + /** + * This returns Directory.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/Directory")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((Directory)object).getName(); + return label == null || label.length() == 0 ? getString("_UI_Directory_type") : //$NON-NLS-1$ + getString("_UI_Directory_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(Directory.class)) + { + case SecurityPackage.DIRECTORY__NAME: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + case SecurityPackage.DIRECTORY__ITEMS: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.DIRECTORY__ITEMS, + SecurityFactory.eINSTANCE.createDirectory())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.DIRECTORY__ITEMS, + SecurityFactory.eINSTANCE.createRole())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.DIRECTORY__ITEMS, + SecurityFactory.eINSTANCE.createGroup())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.DIRECTORY__ITEMS, + SecurityFactory.eINSTANCE.createUser())); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/GroupItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/GroupItemProvider.java new file mode 100644 index 0000000000..aee28b3b49 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/GroupItemProvider.java @@ -0,0 +1,184 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.Group} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class GroupItemProvider extends AssigneeItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public GroupItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addInheritedGroupsPropertyDescriptor(object); + addInheritingGroupsPropertyDescriptor(object); + addUsersPropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Users feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addUsersPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Group_users_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Group_users_feature", "_UI_Group_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.GROUP__USERS, true, false, true, null, null, null)); + } + + /** + * This adds a property descriptor for the Inherited Groups feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addInheritedGroupsPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Group_inheritedGroups_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Group_inheritedGroups_feature", "_UI_Group_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.GROUP__INHERITED_GROUPS, true, false, true, null, null, null)); + } + + /** + * This adds a property descriptor for the Inheriting Groups feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addInheritingGroupsPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Group_inheritingGroups_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Group_inheritingGroups_feature", "_UI_Group_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.GROUP__INHERITING_GROUPS, true, false, true, null, null, null)); + } + + /** + * This returns Group.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/Group")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((Group)object).getId(); + return label == null || label.length() == 0 ? getString("_UI_Group_type") : //$NON-NLS-1$ + getString("_UI_Group_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RealmItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RealmItemProvider.java new file mode 100644 index 0000000000..b75fc58340 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RealmItemProvider.java @@ -0,0 +1,213 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.Realm} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class RealmItemProvider extends SecurityElementItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public RealmItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addNamePropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addNamePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Realm_name_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Realm_name_feature", "_UI_Realm_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.REALM__NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an + * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or + * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) + { + if (childrenFeatures == null) + { + super.getChildrenFeatures(object); + childrenFeatures.add(SecurityPackage.Literals.REALM__ITEMS); + } + return childrenFeatures; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EStructuralFeature getChildFeature(Object object, Object child) + { + // Check the type of the specified child object and return the proper feature to use for + // adding (see {@link AddCommand}) it as a child. + + return super.getChildFeature(object, child); + } + + /** + * This returns Realm.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/Realm")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((Realm)object).getName(); + return label == null || label.length() == 0 ? getString("_UI_Realm_type") : //$NON-NLS-1$ + getString("_UI_Realm_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(Realm.class)) + { + case SecurityPackage.REALM__NAME: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + case SecurityPackage.REALM__ITEMS: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.REALM__ITEMS, + SecurityFactory.eINSTANCE.createDirectory())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.REALM__ITEMS, + SecurityFactory.eINSTANCE.createRole())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.REALM__ITEMS, + SecurityFactory.eINSTANCE.createGroup())); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.REALM__ITEMS, + SecurityFactory.eINSTANCE.createUser())); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RoleItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RoleItemProvider.java new file mode 100644 index 0000000000..d796a4ba7a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/RoleItemProvider.java @@ -0,0 +1,196 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.Role} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class RoleItemProvider extends SecurityItemItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public RoleItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addAssigneesPropertyDescriptor(object); + addIdPropertyDescriptor(object); + addTypePropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Assignees feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addAssigneesPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Role_assignees_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Role_assignees_feature", "_UI_Role_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.ROLE__ASSIGNEES, true, false, true, null, null, null)); + } + + /** + * This adds a property descriptor for the Id feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addIdPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_Role_id_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Role_id_feature", "_UI_Role_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.ROLE__ID, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + + /** + * This adds a property descriptor for the Type feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addTypePropertyDescriptor(Object object) + { + itemPropertyDescriptors + .add(createItemPropertyDescriptor(((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Role_type_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Role_type_feature", "_UI_Role_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.ROLE__TYPE, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * This returns Role.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/Role")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((Role)object).getId(); + return label == null || label.length() == 0 ? getString("_UI_Role_type") : //$NON-NLS-1$ + getString("_UI_Role_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(Role.class)) + { + case SecurityPackage.ROLE__ID: + case SecurityPackage.ROLE__TYPE: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityEditPlugin.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityEditPlugin.java new file mode 100644 index 0000000000..060b32cf46 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityEditPlugin.java @@ -0,0 +1,103 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.edit.CDOEditPlugin; + +import org.eclipse.emf.common.EMFPlugin; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; + +/** + * This is the central singleton for the Security edit plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public final class SecurityEditPlugin extends EMFPlugin +{ + /** + * Keep track of the singleton. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static final SecurityEditPlugin INSTANCE = new SecurityEditPlugin(); + + /** + * Keep track of the singleton. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static Implementation plugin; + + /** + * Create the instance. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityEditPlugin() + { + super(new ResourceLocator[] { EcoreEditPlugin.INSTANCE, CDOEditPlugin.INSTANCE, }); + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the singleton instance. + * @generated + */ + @Override + public ResourceLocator getPluginResourceLocator() + { + return plugin; + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the singleton instance. + * @generated + */ + public static Implementation getPlugin() + { + return plugin; + } + + /** + * The actual implementation of the Eclipse <b>Plugin</b>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static class Implementation extends EclipsePlugin + { + /** + * Creates an instance. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Implementation() + { + super(); + + // Remember the static instance. + // + plugin = this; + } + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityElementItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityElementItemProvider.java new file mode 100644 index 0000000000..69cc68b1b4 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityElementItemProvider.java @@ -0,0 +1,120 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.etypes.provider.ModelElementItemProvider; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.SecurityElement} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityElementItemProvider extends ModelElementItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityElementItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + return getString("_UI_SecurityElement_type"); //$NON-NLS-1$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemItemProvider.java new file mode 100644 index 0000000000..abde7f460a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemItemProvider.java @@ -0,0 +1,118 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.SecurityItem} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityItemItemProvider extends SecurityElementItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityItemItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + return getString("_UI_SecurityItem_type"); //$NON-NLS-1$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemProviderAdapterFactory.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemProviderAdapterFactory.java new file mode 100644 index 0000000000..36f9559850 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/SecurityItemProviderAdapterFactory.java @@ -0,0 +1,426 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.util.SecurityAdapterFactory; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.Notifier; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.edit.domain.EditingDomain; +import org.eclipse.emf.edit.provider.ChangeNotifier; +import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.ComposedAdapterFactory; +import org.eclipse.emf.edit.provider.IChangeNotifier; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IDisposable; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.INotifyChangedListener; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +/** + * This is the factory that is used to provide the interfaces needed to support Viewers. + * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. + * The adapters also support Eclipse property sheets. + * Note that most of the adapters are shared among multiple instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityItemProviderAdapterFactory extends SecurityAdapterFactory implements ComposeableAdapterFactory, + IChangeNotifier, IDisposable, IChildCreationExtender +{ + /** + * This keeps track of the root adapter factory that delegates to this adapter factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ComposedAdapterFactory parentAdapterFactory; + + /** + * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IChangeNotifier changeNotifier = new ChangeNotifier(); + + /** + * This helps manage the child creation extenders. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager( + SecurityEditPlugin.INSTANCE, SecurityPackage.eNS_URI); + + /** + * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<Object> supportedTypes = new ArrayList<Object>(); + + /** + * This constructs an instance. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityItemProviderAdapterFactory() + { + supportedTypes.add(IEditingDomainItemProvider.class); + supportedTypes.add(IStructuredItemContentProvider.class); + supportedTypes.add(ITreeItemContentProvider.class); + supportedTypes.add(IItemLabelProvider.class); + supportedTypes.add(IItemPropertySource.class); + supportedTypes.add(ITableItemLabelProvider.class); + supportedTypes.add(ITableItemColorProvider.class); + supportedTypes.add(ITableItemFontProvider.class); + supportedTypes.add(IItemColorProvider.class); + supportedTypes.add(IItemFontProvider.class); + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.Realm} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected RealmItemProvider realmItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.Realm}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createRealmAdapter() + { + if (realmItemProvider == null) + { + realmItemProvider = new RealmItemProvider(this); + } + + return realmItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.Directory} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected DirectoryItemProvider directoryItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.Directory}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createDirectoryAdapter() + { + if (directoryItemProvider == null) + { + directoryItemProvider = new DirectoryItemProvider(this); + } + + return directoryItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.Role} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected RoleItemProvider roleItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.Role}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createRoleAdapter() + { + if (roleItemProvider == null) + { + roleItemProvider = new RoleItemProvider(this); + } + + return roleItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.Group} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected GroupItemProvider groupItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.Group}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createGroupAdapter() + { + if (groupItemProvider == null) + { + groupItemProvider = new GroupItemProvider(this); + } + + return groupItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.User} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UserItemProvider userItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.User}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createUserAdapter() + { + if (userItemProvider == null) + { + userItemProvider = new UserItemProvider(this); + } + + return userItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link org.eclipse.emf.cdo.security.UserPassword} instances. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UserPasswordItemProvider userPasswordItemProvider; + + /** + * This creates an adapter for a {@link org.eclipse.emf.cdo.security.UserPassword}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter createUserPasswordAdapter() + { + if (userPasswordItemProvider == null) + { + userPasswordItemProvider = new UserPasswordItemProvider(this); + } + + return userPasswordItemProvider; + } + + /** + * This returns the root adapter factory that contains this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ComposeableAdapterFactory getRootAdapterFactory() + { + return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); + } + + /** + * This sets the composed adapter factory that contains this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) + { + this.parentAdapterFactory = parentAdapterFactory; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean isFactoryForType(Object type) + { + return supportedTypes.contains(type) || super.isFactoryForType(type); + } + + /** + * This implementation substitutes the factory itself as the key for the adapter. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Adapter adapt(Notifier notifier, Object type) + { + return super.adapt(notifier, this); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object adapt(Object object, Object type) + { + if (isFactoryForType(type)) + { + Object adapter = super.adapt(object, type); + if (!(type instanceof Class<?>) || ((Class<?>)type).isInstance(adapter)) + { + return adapter; + } + } + + return null; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public List<IChildCreationExtender> getChildCreationExtenders() + { + return childCreationExtenderManager.getChildCreationExtenders(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Collection<?> getNewChildDescriptors(Object object, EditingDomain editingDomain) + { + return childCreationExtenderManager.getNewChildDescriptors(object, editingDomain); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ResourceLocator getResourceLocator() + { + return childCreationExtenderManager; + } + + /** + * This adds a listener. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void addListener(INotifyChangedListener notifyChangedListener) + { + changeNotifier.addListener(notifyChangedListener); + } + + /** + * This removes a listener. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void removeListener(INotifyChangedListener notifyChangedListener) + { + changeNotifier.removeListener(notifyChangedListener); + } + + /** + * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void fireNotifyChanged(Notification notification) + { + changeNotifier.fireNotifyChanged(notification); + + if (parentAdapterFactory != null) + { + parentAdapterFactory.fireNotifyChanged(notification); + } + } + + /** + * This disposes all of the item providers created by this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void dispose() + { + if (realmItemProvider != null) + { + realmItemProvider.dispose(); + } + if (directoryItemProvider != null) + { + directoryItemProvider.dispose(); + } + if (roleItemProvider != null) + { + roleItemProvider.dispose(); + } + if (groupItemProvider != null) + { + groupItemProvider.dispose(); + } + if (userItemProvider != null) + { + userItemProvider.dispose(); + } + if (userPasswordItemProvider != null) + { + userPasswordItemProvider.dispose(); + } + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserItemProvider.java new file mode 100644 index 0000000000..9dd8e137b9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserItemProvider.java @@ -0,0 +1,277 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.User} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class UserItemProvider extends AssigneeItemProvider implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public UserItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addGroupsPropertyDescriptor(object); + addFirstNamePropertyDescriptor(object); + addLastNamePropertyDescriptor(object); + addEmailPropertyDescriptor(object); + addLockedPropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Groups feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addGroupsPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), getResourceLocator(), + getString("_UI_User_groups_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_User_groups_feature", "_UI_User_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER__GROUPS, true, false, true, null, null, null)); + } + + /** + * This adds a property descriptor for the First Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addFirstNamePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_User_firstName_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_User_firstName_feature", "_UI_User_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER__FIRST_NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, + null, null)); + } + + /** + * This adds a property descriptor for the Last Name feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addLastNamePropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_User_lastName_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_User_lastName_feature", "_UI_User_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER__LAST_NAME, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * This adds a property descriptor for the Email feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addEmailPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_User_email_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_User_email_feature", "_UI_User_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER__EMAIL, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, + null)); + } + + /** + * This adds a property descriptor for the Locked feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addLockedPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_User_locked_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_User_locked_feature", "_UI_User_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER__LOCKED, true, false, false, ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, + null)); + } + + /** + * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an + * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or + * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Collection<? extends EStructuralFeature> getChildrenFeatures(Object object) + { + if (childrenFeatures == null) + { + super.getChildrenFeatures(object); + childrenFeatures.add(SecurityPackage.Literals.USER__PASSWORD); + } + return childrenFeatures; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EStructuralFeature getChildFeature(Object object, Object child) + { + // Check the type of the specified child object and return the proper feature to use for + // adding (see {@link AddCommand}) it as a child. + + return super.getChildFeature(object, child); + } + + /** + * This returns User.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/User")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((User)object).getId(); + return label == null || label.length() == 0 ? getString("_UI_User_type") : //$NON-NLS-1$ + getString("_UI_User_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(User.class)) + { + case SecurityPackage.USER__FIRST_NAME: + case SecurityPackage.USER__LAST_NAME: + case SecurityPackage.USER__EMAIL: + case SecurityPackage.USER__LOCKED: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + case SecurityPackage.USER__PASSWORD: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + + newChildDescriptors.add(createChildParameter(SecurityPackage.Literals.USER__PASSWORD, + SecurityFactory.eINSTANCE.createUserPassword())); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserPasswordItemProvider.java b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserPasswordItemProvider.java new file mode 100644 index 0000000000..ad0ec6be20 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.edit/src/org/eclipse/emf/cdo/security/provider/UserPasswordItemProvider.java @@ -0,0 +1,189 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.provider; + +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import java.util.Collection; +import java.util.List; + +/** + * This is the item provider adapter for a {@link org.eclipse.emf.cdo.security.UserPassword} object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class UserPasswordItemProvider extends ItemProviderAdapter implements IEditingDomainItemProvider, + IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource, + ITableItemLabelProvider, ITableItemColorProvider, ITableItemFontProvider, IItemColorProvider, IItemFontProvider +{ + /** + * This constructs an instance from a factory and a notifier. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public UserPasswordItemProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public List<IItemPropertyDescriptor> getPropertyDescriptors(Object object) + { + if (itemPropertyDescriptors == null) + { + super.getPropertyDescriptors(object); + + addEncryptedPropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Encrypted feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void addEncryptedPropertyDescriptor(Object object) + { + itemPropertyDescriptors.add(createItemPropertyDescriptor( + ((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_UserPassword_encrypted_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_UserPassword_encrypted_feature", "_UI_UserPassword_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + SecurityPackage.Literals.USER_PASSWORD__ENCRYPTED, true, false, false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean hasChildren(Object object) + { + return hasChildren(object, true); + } + + /** + * This returns UserPassword.gif. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getImage(Object object) + { + return overlayImage(object, getResourceLocator().getImage("full/obj16/UserPassword")); //$NON-NLS-1$ + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() + { + return true; + } + + /** + * This returns the label text for the adapted class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public String getText(Object object) + { + String label = ((UserPassword)object).getEncrypted(); + return label == null || label.length() == 0 ? getString("_UI_UserPassword_type") : //$NON-NLS-1$ + getString("_UI_UserPassword_type") + " " + label; //$NON-NLS-1$ //$NON-NLS-2$ + } + + /** + * This handles model notifications by calling {@link #updateChildren} to update any cached + * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void notifyChanged(Notification notification) + { + updateChildren(notification); + + switch (notification.getFeatureID(UserPassword.class)) + { + case SecurityPackage.USER_PASSWORD__ENCRYPTED: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + } + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection<Object> newChildDescriptors, Object object) + { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + + /** + * Return the resource locator for this item provider's resources. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public ResourceLocator getResourceLocator() + { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.classpath b/plugins/org.eclipse.emf.cdo.security.editor/.classpath new file mode 100644 index 0000000000..304e86186a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.classpath @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<classpath> + <classpathentry kind="src" path="src"/> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/> + <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> + <classpathentry kind="output" path="bin"/> +</classpath> diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.project b/plugins/org.eclipse.emf.cdo.security.editor/.project new file mode 100644 index 0000000000..d2ceda685a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.project @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.emf.cdo.security.editor</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.ManifestBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.SchemaBuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>org.eclipse.pde.PluginNature</nature> + </natures> +</projectDescription> diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 0000000000..8085bb7dc7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,4 @@ +eclipse.preferences.version=1 +encoding//model/org.eclipse.emf.cdo.defs.ecorediag=UTF-8 +encoding//model/security.ecore=UTF-8 +encoding//model/security.ecorediag=UTF-8 diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..1fa0d45db9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,413 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.cleanOutputFolder=clean +org.eclipse.jdt.core.builder.duplicateResourceTask=warning +org.eclipse.jdt.core.builder.invalidClasspath=abort +org.eclipse.jdt.core.builder.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch,*.ucls,doc-files/,package.html,package-info.java +org.eclipse.jdt.core.circularClasspath=error +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.codeComplete.argumentPrefixes= +org.eclipse.jdt.core.codeComplete.argumentSuffixes= +org.eclipse.jdt.core.codeComplete.fieldPrefixes= +org.eclipse.jdt.core.codeComplete.fieldSuffixes= +org.eclipse.jdt.core.codeComplete.localPrefixes= +org.eclipse.jdt.core.codeComplete.localSuffixes= +org.eclipse.jdt.core.codeComplete.staticFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFieldSuffixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes= +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault +org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable +org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.5 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.doc.comment.support=enabled +org.eclipse.jdt.core.compiler.maxProblemPerUnit=100 +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=warning +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore +org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=warning +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning +org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=warning +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=warning +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.source=1.5 +org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled +org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,HIGH,LOW,LOW,LOW,LOW,LOW +org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,PERF,MEM,POLISH,@generated NOT,@ADDED +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 +org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=1 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 +org.eclipse.jdt.core.formatter.blank_lines_before_method=1 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 +org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=next_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=next_line +org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=next_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=next_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=true +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=true +org.eclipse.jdt.core.formatter.comment.format_block_comments=true +org.eclipse.jdt.core.formatter.comment.format_header=false +org.eclipse.jdt.core.formatter.comment.format_html=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false +org.eclipse.jdt.core.formatter.comment.format_line_comments=true +org.eclipse.jdt.core.formatter.comment.format_source_code=true +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true +org.eclipse.jdt.core.formatter.comment.indent_root_tags=true +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert +org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert +org.eclipse.jdt.core.formatter.comment.line_length=120 +org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true +org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true +org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off +org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false +org.eclipse.jdt.core.formatter.indentation.size=2 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_member=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.join_lines_in_comments=true +org.eclipse.jdt.core.formatter.join_wrapped_lines=true +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.formatter.lineSplit=120 +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true +org.eclipse.jdt.core.formatter.tabulation.char=space +org.eclipse.jdt.core.formatter.tabulation.size=2 +org.eclipse.jdt.core.formatter.use_on_off_tags=false +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=ignore +org.eclipse.jdt.core.incompleteClasspath=error diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.launching.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.launching.prefs new file mode 100644 index 0000000000..556ed07a3c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.launching.prefs @@ -0,0 +1,3 @@ +#Fri Sep 02 05:38:34 CEST 2011 +eclipse.preferences.version=1 +org.eclipse.jdt.launching.PREF_STRICTLY_COMPATIBLE_JRE_NOT_AVAILABLE=ignore diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.ui.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 0000000000..4343e2f963 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,119 @@ +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.always_use_blocks=true +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.convert_to_enhanced_for_loop=false +cleanup.correct_indentation=true +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=false +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=false +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.organize_imports=true +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.remove_private_constructors=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_private_fields=true +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=true +cleanup.remove_unused_private_types=true +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.use_blocks=true +cleanup.use_blocks_only_for_return_and_throw=false +cleanup.use_parentheses_in_expressions=true +cleanup.use_this_for_non_static_field_access=true +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=true +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup_profile=_EMFT +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_EMFT +formatter_settings_version=12 +org.eclipse.jdt.ui.exception.name=ex +org.eclipse.jdt.ui.gettersetter.use.is=true +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=org.eclipse.emf.cdo;org.eclipse.emf.internal.cdo;org.eclipse.net4j;org.eclipse.internal.net4j;org.eclipse.emf;org.eclipse;com;org;javax;java; +org.eclipse.jdt.ui.javadoc=true +org.eclipse.jdt.ui.keywordthis=false +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.overrideannotation=true +org.eclipse.jdt.ui.staticondemandthreshold=99 +org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="false" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment"/><template autoinsert\="false" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment"/><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment"/><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\r\n * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) and others.\r\n * All rights reserved. This program and the accompanying materials\r\n * are made available under the terms of the Eclipse Public License v1.0\r\n * which accompanies this distribution, and is available at\r\n * http\://www.eclipse.org/legal/epl-v10.html\r\n * \r\n * Contributors\:\r\n * Eike Stepper - initial API and implementation\r\n */</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\r\n * @author Eike Stepper\r\n */</template><template autoinsert\="false" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment"/><template autoinsert\="false" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment"/><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment"/><template autoinsert\="false" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment"/><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\r\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\r\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\r\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\r\n</template><template autoinsert\="false" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">${exception_var}.printStackTrace();</template><template autoinsert\="false" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">${body_statement}</template><template autoinsert\="false" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates> +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=false +sp_cleanup.add_serial_version_id=false +sp_cleanup.always_use_blocks=true +sp_cleanup.always_use_parentheses_in_expressions=false +sp_cleanup.always_use_this_for_non_static_field_access=false +sp_cleanup.always_use_this_for_non_static_method_access=false +sp_cleanup.convert_to_enhanced_for_loop=false +sp_cleanup.correct_indentation=true +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.make_local_variable_final=false +sp_cleanup.make_parameters_final=false +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=false +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.organize_imports=true +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.remove_private_constructors=true +sp_cleanup.remove_trailing_whitespaces=true +sp_cleanup.remove_trailing_whitespaces_all=true +sp_cleanup.remove_trailing_whitespaces_ignore_empty=false +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_private_fields=true +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=true +sp_cleanup.remove_unused_private_types=true +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.use_blocks=true +sp_cleanup.use_blocks_only_for_return_and_throw=false +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_this_for_non_static_field_access=true +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=true +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.ltk.core.refactoring.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.ltk.core.refactoring.prefs new file mode 100644 index 0000000000..864e30fe5d --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.ltk.core.refactoring.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +org.eclipse.ltk.core.refactoring.enable.project.refactoring.history=false diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.tasks.ui.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.tasks.ui.prefs new file mode 100644 index 0000000000..b050639a54 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.tasks.ui.prefs @@ -0,0 +1,4 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +project.repository.kind=bugzilla +project.repository.url=https\://bugs.eclipse.org/bugs diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.team.ui.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.team.ui.prefs new file mode 100644 index 0000000000..2f50f36c0c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.mylyn.team.ui.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +commit.comment.template=[${task.id}] ${task.description} \r\n${task.url} +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.api.tools.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.api.tools.prefs new file mode 100644 index 0000000000..f8d0a0660e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.api.tools.prefs @@ -0,0 +1,94 @@ +#Thu Feb 04 09:44:24 CET 2010 +ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error +ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error +CLASS_ELEMENT_TYPE_ADDED_METHOD=Error +CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error +CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error +CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error +CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error +ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error +ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error +ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +FIELD_ELEMENT_TYPE_ADDED_VALUE=Error +FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error +FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error +FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error +FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error +ILLEGAL_EXTEND=Warning +ILLEGAL_IMPLEMENT=Warning +ILLEGAL_INSTANTIATE=Warning +ILLEGAL_OVERRIDE=Warning +ILLEGAL_REFERENCE=Warning +INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error +INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error +INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error +INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +INVALID_JAVADOC_TAG=Ignore +INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Ignore +LEAK_EXTEND=Warning +LEAK_FIELD_DECL=Warning +LEAK_IMPLEMENT=Warning +LEAK_METHOD_PARAM=Warning +LEAK_METHOD_RETURN_TYPE=Warning +METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error +METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error +UNUSED_PROBLEM_FILTERS=Ignore +automatically_removed_unused_problem_filters=Disabled +eclipse.preferences.version=1 +incompatible_api_component_version=Error +incompatible_api_component_version_include_major_without_breaking_change=Disabled +incompatible_api_component_version_include_minor_without_api_change=Disabled +invalid_since_tag_version=Error +malformed_since_tag=Error +missing_since_tag=Error +report_api_breakage_when_major_version_incremented=Disabled +report_resolution_errors_api_component=Warning diff --git a/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.prefs b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.prefs new file mode 100644 index 0000000000..c6b96bb45e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/.settings/org.eclipse.pde.prefs @@ -0,0 +1,31 @@ +#Thu Feb 04 09:44:24 CET 2010 +compilers.f.unresolved-features=1 +compilers.f.unresolved-plugins=1 +compilers.incompatible-environment=1 +compilers.p.build=1 +compilers.p.build.bin.includes=1 +compilers.p.build.java.compliance=1 +compilers.p.build.missing.output=2 +compilers.p.build.output.library=1 +compilers.p.build.source.library=1 +compilers.p.build.src.includes=1 +compilers.p.deprecated=1 +compilers.p.discouraged-class=1 +compilers.p.internal=1 +compilers.p.missing-packages=1 +compilers.p.missing-version-export-package=1 +compilers.p.missing-version-import-package=1 +compilers.p.missing-version-require-bundle=1 +compilers.p.no-required-att=0 +compilers.p.not-externalized-att=2 +compilers.p.unknown-attribute=1 +compilers.p.unknown-class=1 +compilers.p.unknown-element=1 +compilers.p.unknown-identifier=1 +compilers.p.unknown-resource=1 +compilers.p.unresolved-ex-points=0 +compilers.p.unresolved-import=0 +compilers.s.create-docs=false +compilers.s.doc-folder=doc +compilers.s.open-tags=1 +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.cdo.security.editor/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..fa1002678c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/META-INF/MANIFEST.MF @@ -0,0 +1,19 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-SymbolicName: org.eclipse.emf.cdo.security.editor;singleton:=true +Bundle-Version: 4.1.0.qualifier +Bundle-Localization: plugin +Bundle-Name: %pluginName +Bundle-Vendor: %providerName +Bundle-ClassPath: . +Bundle-Activator: org.eclipse.emf.cdo.security.presentation.SecurityEditorPlugin$Implementation +Bundle-RequiredExecutionEnvironment: J2SE-1.5 +Export-Package: org.eclipse.emf.cdo.security.presentation;version="4.1.0" +Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.4.0,4.0.0)", + org.eclipse.core.resources;bundle-version="[3.4.0,4.0.0)";visibility:=reexport, + org.eclipse.ui.ide;bundle-version="[3.4.0,4.0.0)";visibility:=reexport, + org.eclipse.emf.ecore.xmi;bundle-version="[2.4.0,3.0.0)";visibility:=reexport, + org.eclipse.emf.edit.ui;bundle-version="[2.4.0,3.0.0)";visibility:=reexport, + org.eclipse.emf.ecore.edit;bundle-version="[2.4.0,3.0.0)";visibility:=reexport, + org.eclipse.emf.cdo.security.edit;bundle-version="[4.1.0,5.0.0)";visibility:=reexport +Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.cdo.security.editor/about.html b/plugins/org.eclipse.emf.cdo.security.editor/about.html new file mode 100644 index 0000000000..d35d5aed64 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 5, 2007</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise +indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html> diff --git a/plugins/org.eclipse.emf.cdo.security.editor/build.properties b/plugins/org.eclipse.emf.cdo.security.editor/build.properties new file mode 100644 index 0000000000..bc81aa2cb0 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/build.properties @@ -0,0 +1,14 @@ +# + +bin.includes = .,\ + icons/,\ + META-INF/,\ + plugin.xml,\ + plugin.properties,\ + about.html,\ + copyright.txt +jars.compile.order = . +source.. = src/ +output.. = bin +src.includes = about.html,\ + copyright.txt diff --git a/plugins/org.eclipse.emf.cdo.security.editor/copyright.txt b/plugins/org.eclipse.emf.cdo.security.editor/copyright.txt new file mode 100644 index 0000000000..0a0f67e6d7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/copyright.txt @@ -0,0 +1,8 @@ +Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation
\ No newline at end of file diff --git a/plugins/org.eclipse.emf.cdo.security.editor/icons/full/obj16/SecurityModelFile.gif b/plugins/org.eclipse.emf.cdo.security.editor/icons/full/obj16/SecurityModelFile.gif Binary files differnew file mode 100644 index 0000000000..66b71ecf1b --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/icons/full/obj16/SecurityModelFile.gif diff --git a/plugins/org.eclipse.emf.cdo.security.editor/icons/full/wizban/NewSecurity.gif b/plugins/org.eclipse.emf.cdo.security.editor/icons/full/wizban/NewSecurity.gif Binary files differnew file mode 100644 index 0000000000..35743ceb88 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/icons/full/wizban/NewSecurity.gif diff --git a/plugins/org.eclipse.emf.cdo.security.editor/plugin.properties b/plugins/org.eclipse.emf.cdo.security.editor/plugin.properties new file mode 100644 index 0000000000..7adba19192 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/plugin.properties @@ -0,0 +1,54 @@ +# Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: +# Eike Stepper - initial API and implementation + +pluginName = CDO Model Repository Security Editor +providerName = Eclipse Modeling Project + + +_UI_SecurityEditor_menu = &Security Editor + +_UI_CreateChild_menu_item = &New Child +_UI_CreateSibling_menu_item = N&ew Sibling + +_UI_ShowPropertiesView_menu_item = Show &Properties View +_UI_RefreshViewer_menu_item = &Refresh + +_UI_SelectionPage_label = Selection + +_UI_NoObjectSelected = Selected Nothing +_UI_SingleObjectSelected = Selected Object: {0} +_UI_MultiObjectSelected = Selected {0} Objects + +_UI_OpenEditorError_label = Open Editor + +_UI_Wizard_category = Example EMF Model Creation Wizards + +_UI_CreateModelError_message = Problems encountered in file "{0}" + +_UI_SecurityModelWizard_label = Security Model +_UI_SecurityModelWizard_description = Create a new Security model + +_UI_SecurityEditor_label = Security Model Editor + +_UI_SecurityEditorFilenameDefaultBase = My +_UI_SecurityEditorFilenameExtensions = security + +_UI_Wizard_label = New + +_WARN_FilenameExtension = The file name must end in ''.{0}'' +_WARN_FilenameExtensions = The file name must have one of the following extensions: {0} + +_UI_ModelObject = &Model Object +_UI_XMLEncoding = &XML Encoding +_UI_XMLEncodingChoices = UTF-8 ASCII UTF-16 UTF-16BE UTF-16LE ISO-8859-1 +_UI_Wizard_initial_object_description = Select a model object to create + +_UI_FileConflict_label = File Conflict +_WARN_FileConflict = There are unsaved changes that conflict with changes made outside the editor. Do you wish to discard this editor's changes? + diff --git a/plugins/org.eclipse.emf.cdo.security.editor/plugin.xml b/plugins/org.eclipse.emf.cdo.security.editor/plugin.xml new file mode 100644 index 0000000000..3313c674d1 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/plugin.xml @@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?eclipse version="3.4"?> +<!-- + Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation +--> + +<plugin> + + <extension point="org.eclipse.ui.newWizards"> + <category + id="org.eclipse.emf.ecore.Wizard.category.ID" + name="%_UI_Wizard_category"/> + <wizard + id="org.eclipse.emf.cdo.security.presentation.SecurityModelWizardID" + name="%_UI_SecurityModelWizard_label" + class="org.eclipse.emf.cdo.security.presentation.SecurityModelWizard" + category="org.eclipse.emf.ecore.Wizard.category.ID" + icon="icons/full/obj16/SecurityModelFile.gif"> + <description>%_UI_SecurityModelWizard_description</description> + <selection class="org.eclipse.core.resources.IResource"/> + </wizard> + </extension> + + <extension point="org.eclipse.ui.editors"> + <editor + id="org.eclipse.emf.cdo.security.presentation.SecurityEditorID" + name="%_UI_SecurityEditor_label" + icon="icons/full/obj16/SecurityModelFile.gif" + extensions="security" + class="org.eclipse.emf.cdo.security.presentation.SecurityEditor" + contributorClass="org.eclipse.emf.cdo.security.presentation.SecurityActionBarContributor"> + </editor> + </extension> + +</plugin> diff --git a/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityActionBarContributor.java b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityActionBarContributor.java new file mode 100644 index 0000000000..7f56342b67 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityActionBarContributor.java @@ -0,0 +1,473 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.presentation; + +import org.eclipse.emf.common.ui.viewer.IViewerProvider; +import org.eclipse.emf.edit.domain.EditingDomain; +import org.eclipse.emf.edit.domain.IEditingDomainProvider; +import org.eclipse.emf.edit.ui.action.ControlAction; +import org.eclipse.emf.edit.ui.action.CreateChildAction; +import org.eclipse.emf.edit.ui.action.CreateSiblingAction; +import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; +import org.eclipse.emf.edit.ui.action.LoadResourceAction; +import org.eclipse.emf.edit.ui.action.ValidateAction; + +import org.eclipse.jface.action.Action; +import org.eclipse.jface.action.ActionContributionItem; +import org.eclipse.jface.action.IAction; +import org.eclipse.jface.action.IContributionItem; +import org.eclipse.jface.action.IContributionManager; +import org.eclipse.jface.action.IMenuListener; +import org.eclipse.jface.action.IMenuManager; +import org.eclipse.jface.action.IToolBarManager; +import org.eclipse.jface.action.MenuManager; +import org.eclipse.jface.action.Separator; +import org.eclipse.jface.action.SubContributionItem; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.ISelectionChangedListener; +import org.eclipse.jface.viewers.ISelectionProvider; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.viewers.SelectionChangedEvent; +import org.eclipse.jface.viewers.Viewer; +import org.eclipse.ui.IEditorPart; +import org.eclipse.ui.PartInitException; + +import java.util.ArrayList; +import java.util.Collection; + +/** + * This is the action bar contributor for the Security model editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityActionBarContributor extends EditingDomainActionBarContributor implements + ISelectionChangedListener +{ + /** + * This keeps track of the active editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IEditorPart activeEditorPart; + + /** + * This keeps track of the current selection provider. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ISelectionProvider selectionProvider; + + /** + * This action opens the Properties view. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IAction showPropertiesViewAction = new Action( + SecurityEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) //$NON-NLS-1$ + { + @Override + public void run() + { + try + { + getPage().showView("org.eclipse.ui.views.PropertySheet"); //$NON-NLS-1$ + } + catch (PartInitException exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + } + }; + + /** + * This action refreshes the viewer of the current editor if the editor + * implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IAction refreshViewerAction = new Action( + SecurityEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) //$NON-NLS-1$ + { + @Override + public boolean isEnabled() + { + return activeEditorPart instanceof IViewerProvider; + } + + @Override + public void run() + { + if (activeEditorPart instanceof IViewerProvider) + { + Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer(); + if (viewer != null) + { + viewer.refresh(); + } + } + } + }; + + /** + * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor + * generated for the current selection by the item provider. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<IAction> createChildActions; + + /** + * This is the menu manager into which menu contribution items should be added for CreateChild actions. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IMenuManager createChildMenuManager; + + /** + * This will contain one {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} corresponding to each descriptor + * generated for the current selection by the item provider. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<IAction> createSiblingActions; + + /** + * This is the menu manager into which menu contribution items should be added for CreateSibling actions. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IMenuManager createSiblingMenuManager; + + /** + * This creates an instance of the contributor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityActionBarContributor() + { + super(ADDITIONS_LAST_STYLE); + loadResourceAction = new LoadResourceAction(); + validateAction = new ValidateAction(); + controlAction = new ControlAction(); + } + + /** + * This adds Separators for editor additions to the tool bar. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void contributeToToolBar(IToolBarManager toolBarManager) + { + toolBarManager.add(new Separator("security-settings")); //$NON-NLS-1$ + toolBarManager.add(new Separator("security-additions")); //$NON-NLS-1$ + } + + /** + * This adds to the menu bar a menu and some separators for editor additions, + * as well as the sub-menus for object creation items. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void contributeToMenu(IMenuManager menuManager) + { + super.contributeToMenu(menuManager); + + IMenuManager submenuManager = new MenuManager( + SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityEditor_menu"), "org.eclipse.emf.cdo.securityMenuID"); //$NON-NLS-1$ //$NON-NLS-2$ + menuManager.insertAfter("additions", submenuManager); //$NON-NLS-1$ + submenuManager.add(new Separator("settings")); //$NON-NLS-1$ + submenuManager.add(new Separator("actions")); //$NON-NLS-1$ + submenuManager.add(new Separator("additions")); //$NON-NLS-1$ + submenuManager.add(new Separator("additions-end")); //$NON-NLS-1$ + + // Prepare for CreateChild item addition or removal. + // + createChildMenuManager = new MenuManager(SecurityEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); //$NON-NLS-1$ + submenuManager.insertBefore("additions", createChildMenuManager); //$NON-NLS-1$ + + // Prepare for CreateSibling item addition or removal. + // + createSiblingMenuManager = new MenuManager(SecurityEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); //$NON-NLS-1$ + submenuManager.insertBefore("additions", createSiblingMenuManager); //$NON-NLS-1$ + + // Force an update because Eclipse hides empty menus now. + // + submenuManager.addMenuListener(new IMenuListener() + { + public void menuAboutToShow(IMenuManager menuManager) + { + menuManager.updateAll(true); + } + }); + + addGlobalActions(submenuManager); + } + + /** + * When the active editor changes, this remembers the change and registers with it as a selection provider. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void setActiveEditor(IEditorPart part) + { + super.setActiveEditor(part); + activeEditorPart = part; + + // Switch to the new selection provider. + // + if (selectionProvider != null) + { + selectionProvider.removeSelectionChangedListener(this); + } + if (part == null) + { + selectionProvider = null; + } + else + { + selectionProvider = part.getSite().getSelectionProvider(); + selectionProvider.addSelectionChangedListener(this); + + // Fake a selection changed event to update the menus. + // + if (selectionProvider.getSelection() != null) + { + selectionChanged(new SelectionChangedEvent(selectionProvider, selectionProvider.getSelection())); + } + } + } + + /** + * This implements {@link org.eclipse.jface.viewers.ISelectionChangedListener}, + * handling {@link org.eclipse.jface.viewers.SelectionChangedEvent}s by querying for the children and siblings + * that can be added to the selected object and updating the menus accordingly. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void selectionChanged(SelectionChangedEvent event) + { + // Remove any menu items for old selection. + // + if (createChildMenuManager != null) + { + depopulateManager(createChildMenuManager, createChildActions); + } + if (createSiblingMenuManager != null) + { + depopulateManager(createSiblingMenuManager, createSiblingActions); + } + + // Query the new selection for appropriate new child/sibling descriptors + // + Collection<?> newChildDescriptors = null; + Collection<?> newSiblingDescriptors = null; + + ISelection selection = event.getSelection(); + if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) + { + Object object = ((IStructuredSelection)selection).getFirstElement(); + + EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain(); + + newChildDescriptors = domain.getNewChildDescriptors(object, null); + newSiblingDescriptors = domain.getNewChildDescriptors(null, object); + } + + // Generate actions for selection; populate and redraw the menus. + // + createChildActions = generateCreateChildActions(newChildDescriptors, selection); + createSiblingActions = generateCreateSiblingActions(newSiblingDescriptors, selection); + + if (createChildMenuManager != null) + { + populateManager(createChildMenuManager, createChildActions, null); + createChildMenuManager.update(true); + } + if (createSiblingMenuManager != null) + { + populateManager(createSiblingMenuManager, createSiblingActions, null); + createSiblingMenuManager.update(true); + } + } + + /** + * This generates a {@link org.eclipse.emf.edit.ui.action.CreateChildAction} for each object in <code>descriptors</code>, + * and returns the collection of these actions. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<IAction> generateCreateChildActions(Collection<?> descriptors, ISelection selection) + { + Collection<IAction> actions = new ArrayList<IAction>(); + if (descriptors != null) + { + for (Object descriptor : descriptors) + { + actions.add(new CreateChildAction(activeEditorPart, selection, descriptor)); + } + } + return actions; + } + + /** + * This generates a {@link org.eclipse.emf.edit.ui.action.CreateSiblingAction} for each object in <code>descriptors</code>, + * and returns the collection of these actions. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<IAction> generateCreateSiblingActions(Collection<?> descriptors, ISelection selection) + { + Collection<IAction> actions = new ArrayList<IAction>(); + if (descriptors != null) + { + for (Object descriptor : descriptors) + { + actions.add(new CreateSiblingAction(activeEditorPart, selection, descriptor)); + } + } + return actions; + } + + /** + * This populates the specified <code>manager</code> with {@link org.eclipse.jface.action.ActionContributionItem}s + * based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection, + * by inserting them before the specified contribution item <code>contributionID</code>. + * If <code>contributionID</code> is <code>null</code>, they are simply added. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void populateManager(IContributionManager manager, Collection<? extends IAction> actions, + String contributionID) + { + if (actions != null) + { + for (IAction action : actions) + { + if (contributionID != null) + { + manager.insertBefore(contributionID, action); + } + else + { + manager.add(action); + } + } + } + } + + /** + * This removes from the specified <code>manager</code> all {@link org.eclipse.jface.action.ActionContributionItem}s + * based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void depopulateManager(IContributionManager manager, Collection<? extends IAction> actions) + { + if (actions != null) + { + IContributionItem[] items = manager.getItems(); + for (int i = 0; i < items.length; i++) + { + // Look into SubContributionItems + // + IContributionItem contributionItem = items[i]; + while (contributionItem instanceof SubContributionItem) + { + contributionItem = ((SubContributionItem)contributionItem).getInnerItem(); + } + + // Delete the ActionContributionItems with matching action. + // + if (contributionItem instanceof ActionContributionItem) + { + IAction action = ((ActionContributionItem)contributionItem).getAction(); + if (actions.contains(action)) + { + manager.remove(contributionItem); + } + } + } + } + } + + /** + * This populates the pop-up menu before it appears. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void menuAboutToShow(IMenuManager menuManager) + { + super.menuAboutToShow(menuManager); + MenuManager submenuManager = null; + + submenuManager = new MenuManager(SecurityEditorPlugin.INSTANCE.getString("_UI_CreateChild_menu_item")); //$NON-NLS-1$ + populateManager(submenuManager, createChildActions, null); + menuManager.insertBefore("edit", submenuManager); //$NON-NLS-1$ + + submenuManager = new MenuManager(SecurityEditorPlugin.INSTANCE.getString("_UI_CreateSibling_menu_item")); //$NON-NLS-1$ + populateManager(submenuManager, createSiblingActions, null); + menuManager.insertBefore("edit", submenuManager); //$NON-NLS-1$ + } + + /** + * This inserts global actions before the "additions-end" separator. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void addGlobalActions(IMenuManager menuManager) + { + menuManager.insertAfter("additions-end", new Separator("ui-actions")); //$NON-NLS-1$ //$NON-NLS-2$ + menuManager.insertAfter("ui-actions", showPropertiesViewAction); //$NON-NLS-1$ + + refreshViewerAction.setEnabled(refreshViewerAction.isEnabled()); + menuManager.insertAfter("ui-actions", refreshViewerAction); //$NON-NLS-1$ + + super.addGlobalActions(menuManager); + } + + /** + * This ensures that a delete action will clean up all references to deleted objects. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean removeAllReferencesOnDelete() + { + return true; + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditor.java b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditor.java new file mode 100644 index 0000000000..efba1b23f7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditor.java @@ -0,0 +1,1694 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.presentation; + +import org.eclipse.emf.cdo.etypes.provider.EtypesItemProviderAdapterFactory; +import org.eclipse.emf.cdo.security.provider.SecurityItemProviderAdapterFactory; + +import org.eclipse.emf.common.command.BasicCommandStack; +import org.eclipse.emf.common.command.Command; +import org.eclipse.emf.common.command.CommandStack; +import org.eclipse.emf.common.command.CommandStackListener; +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.ui.MarkerHelper; +import org.eclipse.emf.common.ui.editor.ProblemEditorPart; +import org.eclipse.emf.common.ui.viewer.IViewerProvider; +import org.eclipse.emf.common.util.BasicDiagnostic; +import org.eclipse.emf.common.util.Diagnostic; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EValidator; +import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.resource.ResourceSet; +import org.eclipse.emf.ecore.util.EContentAdapter; +import org.eclipse.emf.ecore.util.EcoreUtil; +import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain; +import org.eclipse.emf.edit.domain.EditingDomain; +import org.eclipse.emf.edit.domain.IEditingDomainProvider; +import org.eclipse.emf.edit.provider.AdapterFactoryItemDelegator; +import org.eclipse.emf.edit.provider.ComposedAdapterFactory; +import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory; +import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory; +import org.eclipse.emf.edit.ui.action.EditingDomainActionBarContributor; +import org.eclipse.emf.edit.ui.celleditor.AdapterFactoryTreeEditor; +import org.eclipse.emf.edit.ui.dnd.EditingDomainViewerDropAdapter; +import org.eclipse.emf.edit.ui.dnd.LocalTransfer; +import org.eclipse.emf.edit.ui.dnd.ViewerDragAdapter; +import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider; +import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider; +import org.eclipse.emf.edit.ui.provider.UnwrappingSelectionProvider; +import org.eclipse.emf.edit.ui.util.EditUIMarkerHelper; +import org.eclipse.emf.edit.ui.util.EditUIUtil; +import org.eclipse.emf.edit.ui.view.ExtendedPropertySheetPage; + +import org.eclipse.core.resources.IFile; +import org.eclipse.core.resources.IMarker; +import org.eclipse.core.resources.IResource; +import org.eclipse.core.resources.IResourceChangeEvent; +import org.eclipse.core.resources.IResourceChangeListener; +import org.eclipse.core.resources.IResourceDelta; +import org.eclipse.core.resources.IResourceDeltaVisitor; +import org.eclipse.core.resources.ResourcesPlugin; +import org.eclipse.core.runtime.CoreException; +import org.eclipse.core.runtime.IPath; +import org.eclipse.core.runtime.IProgressMonitor; +import org.eclipse.core.runtime.NullProgressMonitor; +import org.eclipse.jface.action.IMenuListener; +import org.eclipse.jface.action.IMenuManager; +import org.eclipse.jface.action.IStatusLineManager; +import org.eclipse.jface.action.IToolBarManager; +import org.eclipse.jface.action.MenuManager; +import org.eclipse.jface.action.Separator; +import org.eclipse.jface.dialogs.MessageDialog; +import org.eclipse.jface.dialogs.ProgressMonitorDialog; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.ISelectionChangedListener; +import org.eclipse.jface.viewers.ISelectionProvider; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.viewers.SelectionChangedEvent; +import org.eclipse.jface.viewers.StructuredSelection; +import org.eclipse.jface.viewers.StructuredViewer; +import org.eclipse.jface.viewers.TreeViewer; +import org.eclipse.jface.viewers.Viewer; +import org.eclipse.swt.SWT; +import org.eclipse.swt.custom.CTabFolder; +import org.eclipse.swt.dnd.DND; +import org.eclipse.swt.dnd.Transfer; +import org.eclipse.swt.events.ControlAdapter; +import org.eclipse.swt.events.ControlEvent; +import org.eclipse.swt.graphics.Point; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Menu; +import org.eclipse.swt.widgets.Tree; +import org.eclipse.ui.IActionBars; +import org.eclipse.ui.IEditorInput; +import org.eclipse.ui.IEditorPart; +import org.eclipse.ui.IEditorSite; +import org.eclipse.ui.IPartListener; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.PartInitException; +import org.eclipse.ui.actions.WorkspaceModifyOperation; +import org.eclipse.ui.dialogs.SaveAsDialog; +import org.eclipse.ui.ide.IGotoMarker; +import org.eclipse.ui.part.FileEditorInput; +import org.eclipse.ui.part.MultiPageEditorPart; +import org.eclipse.ui.views.contentoutline.ContentOutline; +import org.eclipse.ui.views.contentoutline.ContentOutlinePage; +import org.eclipse.ui.views.contentoutline.IContentOutlinePage; +import org.eclipse.ui.views.properties.IPropertySheetPage; +import org.eclipse.ui.views.properties.PropertySheet; +import org.eclipse.ui.views.properties.PropertySheetPage; + +import java.io.IOException; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.EventObject; +import java.util.HashMap; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; + +/** + * This is an example of a Security model editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityEditor extends MultiPageEditorPart implements IEditingDomainProvider, ISelectionProvider, + IMenuListener, IViewerProvider, IGotoMarker +{ + /** + * This keeps track of the editing domain that is used to track all changes to the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AdapterFactoryEditingDomain editingDomain; + + /** + * This is the one adapter factory used for providing views of the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ComposedAdapterFactory adapterFactory; + + /** + * This is the content outline page. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IContentOutlinePage contentOutlinePage; + + /** + * This is a kludge... + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IStatusLineManager contentOutlineStatusLineManager; + + /** + * This is the content outline page's viewer. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected TreeViewer contentOutlineViewer; + + /** + * This is the property sheet page. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected PropertySheetPage propertySheetPage; + + /** + * This is the viewer that shadows the selection in the content outline. + * The parent relation must be correctly defined for this to work. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected TreeViewer selectionViewer; + + /** + * This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Viewer currentViewer; + + /** + * This listens to which ever viewer is active. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ISelectionChangedListener selectionChangedListener; + + /** + * This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<ISelectionChangedListener> selectionChangedListeners = new ArrayList<ISelectionChangedListener>(); + + /** + * This keeps track of the selection of the editor as a whole. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ISelection editorSelection = StructuredSelection.EMPTY; + + /** + * The MarkerHelper is responsible for creating workspace resource markers presented + * in Eclipse's Problems View. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected MarkerHelper markerHelper = new EditUIMarkerHelper(); + + /** + * This listens for when the outline becomes active + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IPartListener partListener = new IPartListener() + { + public void partActivated(IWorkbenchPart p) + { + if (p instanceof ContentOutline) + { + if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) + { + getActionBarContributor().setActiveEditor(SecurityEditor.this); + + setCurrentViewer(contentOutlineViewer); + } + } + else if (p instanceof PropertySheet) + { + if (((PropertySheet)p).getCurrentPage() == propertySheetPage) + { + getActionBarContributor().setActiveEditor(SecurityEditor.this); + handleActivate(); + } + } + else if (p == SecurityEditor.this) + { + handleActivate(); + } + } + + public void partBroughtToTop(IWorkbenchPart p) + { + // Ignore. + } + + public void partClosed(IWorkbenchPart p) + { + // Ignore. + } + + public void partDeactivated(IWorkbenchPart p) + { + // Ignore. + } + + public void partOpened(IWorkbenchPart p) + { + // Ignore. + } + }; + + /** + * Resources that have been removed since last activation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<Resource> removedResources = new ArrayList<Resource>(); + + /** + * Resources that have been changed since last activation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<Resource> changedResources = new ArrayList<Resource>(); + + /** + * Resources that have been saved. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<Resource> savedResources = new ArrayList<Resource>(); + + /** + * Map to store the diagnostic associated with a resource. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Map<Resource, Diagnostic> resourceToDiagnosticMap = new LinkedHashMap<Resource, Diagnostic>(); + + /** + * Controls whether the problem indication should be updated. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected boolean updateProblemIndication = true; + + /** + * Adapter used to update the problem indication when resources are demanded loaded. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected EContentAdapter problemIndicationAdapter = new EContentAdapter() + { + @Override + public void notifyChanged(Notification notification) + { + if (notification.getNotifier() instanceof Resource) + { + switch (notification.getFeatureID(Resource.class)) + { + case Resource.RESOURCE__IS_LOADED: + case Resource.RESOURCE__ERRORS: + case Resource.RESOURCE__WARNINGS: + { + Resource resource = (Resource)notification.getNotifier(); + Diagnostic diagnostic = analyzeResourceProblems(resource, null); + if (diagnostic.getSeverity() != Diagnostic.OK) + { + resourceToDiagnosticMap.put(resource, diagnostic); + } + else + { + resourceToDiagnosticMap.remove(resource); + } + + if (updateProblemIndication) + { + getSite().getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + updateProblemIndication(); + } + }); + } + break; + } + } + } + else + { + super.notifyChanged(notification); + } + } + + @Override + protected void setTarget(Resource target) + { + basicSetTarget(target); + } + + @Override + protected void unsetTarget(Resource target) + { + basicUnsetTarget(target); + } + }; + + /** + * This listens for workspace changes. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IResourceChangeListener resourceChangeListener = new IResourceChangeListener() + { + public void resourceChanged(IResourceChangeEvent event) + { + IResourceDelta delta = event.getDelta(); + try + { + class ResourceDeltaVisitor implements IResourceDeltaVisitor + { + protected ResourceSet resourceSet = editingDomain.getResourceSet(); + + protected Collection<Resource> changedResources = new ArrayList<Resource>(); + + protected Collection<Resource> removedResources = new ArrayList<Resource>(); + + public boolean visit(IResourceDelta delta) + { + if (delta.getResource().getType() == IResource.FILE) + { + if (delta.getKind() == IResourceDelta.REMOVED || delta.getKind() == IResourceDelta.CHANGED + && delta.getFlags() != IResourceDelta.MARKERS) + { + Resource resource = resourceSet.getResource( + URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false); + if (resource != null) + { + if (delta.getKind() == IResourceDelta.REMOVED) + { + removedResources.add(resource); + } + else if (!savedResources.remove(resource)) + { + changedResources.add(resource); + } + } + } + } + + return true; + } + + public Collection<Resource> getChangedResources() + { + return changedResources; + } + + public Collection<Resource> getRemovedResources() + { + return removedResources; + } + } + + final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor(); + delta.accept(visitor); + + if (!visitor.getRemovedResources().isEmpty()) + { + getSite().getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + removedResources.addAll(visitor.getRemovedResources()); + if (!isDirty()) + { + getSite().getPage().closeEditor(SecurityEditor.this, false); + } + } + }); + } + + if (!visitor.getChangedResources().isEmpty()) + { + getSite().getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + changedResources.addAll(visitor.getChangedResources()); + if (getSite().getPage().getActiveEditor() == SecurityEditor.this) + { + handleActivate(); + } + } + }); + } + } + catch (CoreException exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + } + }; + + /** + * Handles activation of the editor or it's associated views. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void handleActivate() + { + // Recompute the read only state. + // + if (editingDomain.getResourceToReadOnlyMap() != null) + { + editingDomain.getResourceToReadOnlyMap().clear(); + + // Refresh any actions that may become enabled or disabled. + // + setSelection(getSelection()); + } + + if (!removedResources.isEmpty()) + { + if (handleDirtyConflict()) + { + getSite().getPage().closeEditor(SecurityEditor.this, false); + } + else + { + removedResources.clear(); + changedResources.clear(); + savedResources.clear(); + } + } + else if (!changedResources.isEmpty()) + { + changedResources.removeAll(savedResources); + handleChangedResources(); + changedResources.clear(); + savedResources.clear(); + } + } + + /** + * Handles what to do with changed resources on activation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void handleChangedResources() + { + if (!changedResources.isEmpty() && (!isDirty() || handleDirtyConflict())) + { + if (isDirty()) + { + changedResources.addAll(editingDomain.getResourceSet().getResources()); + } + editingDomain.getCommandStack().flush(); + + updateProblemIndication = false; + for (Resource resource : changedResources) + { + if (resource.isLoaded()) + { + resource.unload(); + try + { + resource.load(Collections.EMPTY_MAP); + } + catch (IOException exception) + { + if (!resourceToDiagnosticMap.containsKey(resource)) + { + resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); + } + } + } + } + + if (AdapterFactoryEditingDomain.isStale(editorSelection)) + { + setSelection(StructuredSelection.EMPTY); + } + + updateProblemIndication = true; + updateProblemIndication(); + } + } + + /** + * Updates the problems indication with the information described in the specified diagnostic. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void updateProblemIndication() + { + if (updateProblemIndication) + { + BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK, "org.eclipse.emf.cdo.security.editor", //$NON-NLS-1$ + 0, null, new Object[] { editingDomain.getResourceSet() }); + for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) + { + if (childDiagnostic.getSeverity() != Diagnostic.OK) + { + diagnostic.add(childDiagnostic); + } + } + + int lastEditorPage = getPageCount() - 1; + if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) + { + ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic); + if (diagnostic.getSeverity() != Diagnostic.OK) + { + setActivePage(lastEditorPage); + } + } + else if (diagnostic.getSeverity() != Diagnostic.OK) + { + ProblemEditorPart problemEditorPart = new ProblemEditorPart(); + problemEditorPart.setDiagnostic(diagnostic); + problemEditorPart.setMarkerHelper(markerHelper); + try + { + addPage(++lastEditorPage, problemEditorPart, getEditorInput()); + setPageText(lastEditorPage, problemEditorPart.getPartName()); + setActivePage(lastEditorPage); + showTabs(); + } + catch (PartInitException exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + } + + if (markerHelper.hasMarkers(editingDomain.getResourceSet())) + { + markerHelper.deleteMarkers(editingDomain.getResourceSet()); + if (diagnostic.getSeverity() != Diagnostic.OK) + { + try + { + markerHelper.createMarkers(diagnostic); + } + catch (CoreException exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + } + } + } + } + + /** + * Shows a dialog that asks if conflicting changes should be discarded. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected boolean handleDirtyConflict() + { + return MessageDialog.openQuestion(getSite().getShell(), getString("_UI_FileConflict_label"), //$NON-NLS-1$ + getString("_WARN_FileConflict")); //$NON-NLS-1$ + } + + /** + * This creates a model editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityEditor() + { + super(); + initializeEditingDomain(); + } + + /** + * This sets up the editing domain for the model editor. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void initializeEditingDomain() + { + // Create an adapter factory that yields item providers. + // + adapterFactory = new ComposedAdapterFactory(ComposedAdapterFactory.Descriptor.Registry.INSTANCE); + + adapterFactory.addAdapterFactory(new ResourceItemProviderAdapterFactory()); + adapterFactory.addAdapterFactory(new SecurityItemProviderAdapterFactory()); + adapterFactory.addAdapterFactory(new EcoreItemProviderAdapterFactory()); + adapterFactory.addAdapterFactory(new EtypesItemProviderAdapterFactory()); + adapterFactory.addAdapterFactory(new ReflectiveItemProviderAdapterFactory()); + + // Create the command stack that will notify this editor as commands are executed. + // + BasicCommandStack commandStack = new BasicCommandStack(); + + // Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus. + // + commandStack.addCommandStackListener(new CommandStackListener() + { + public void commandStackChanged(final EventObject event) + { + getContainer().getDisplay().asyncExec(new Runnable() + { + public void run() + { + firePropertyChange(IEditorPart.PROP_DIRTY); + + // Try to select the affected objects. + // + Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand(); + if (mostRecentCommand != null) + { + setSelectionToViewer(mostRecentCommand.getAffectedObjects()); + } + if (propertySheetPage != null && !propertySheetPage.getControl().isDisposed()) + { + propertySheetPage.refresh(); + } + } + }); + } + }); + + // Create the editing domain with a special command stack. + // + editingDomain = new AdapterFactoryEditingDomain(adapterFactory, commandStack, new HashMap<Resource, Boolean>()); + } + + /** + * This is here for the listener to be able to call it. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void firePropertyChange(int action) + { + super.firePropertyChange(action); + } + + /** + * This sets the selection into whichever viewer is active. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setSelectionToViewer(Collection<?> collection) + { + final Collection<?> theSelection = collection; + // Make sure it's okay. + // + if (theSelection != null && !theSelection.isEmpty()) + { + Runnable runnable = new Runnable() + { + public void run() + { + // Try to select the items in the current content viewer of the editor. + // + if (currentViewer != null) + { + currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true); + } + } + }; + getSite().getShell().getDisplay().asyncExec(runnable); + } + } + + /** + * This returns the editing domain as required by the {@link IEditingDomainProvider} interface. + * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} + * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EditingDomain getEditingDomain() + { + return editingDomain; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider + { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) + { + super(adapterFactory); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object[] getElements(Object object) + { + Object parent = super.getParent(object); + return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object[] getChildren(Object object) + { + Object parent = super.getParent(object); + return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean hasChildren(Object object) + { + Object parent = super.getParent(object); + return parent != null; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public Object getParent(Object object) + { + return null; + } + } + + /** + * This makes sure that one content viewer, either for the current page or the outline view, if it has focus, + * is the current one. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setCurrentViewer(Viewer viewer) + { + // If it is changing... + // + if (currentViewer != viewer) + { + if (selectionChangedListener == null) + { + // Create the listener on demand. + // + selectionChangedListener = new ISelectionChangedListener() + { + // This just notifies those things that are affected by the section. + // + public void selectionChanged(SelectionChangedEvent selectionChangedEvent) + { + setSelection(selectionChangedEvent.getSelection()); + } + }; + } + + // Stop listening to the old one. + // + if (currentViewer != null) + { + currentViewer.removeSelectionChangedListener(selectionChangedListener); + } + + // Start listening to the new one. + // + if (viewer != null) + { + viewer.addSelectionChangedListener(selectionChangedListener); + } + + // Remember it. + // + currentViewer = viewer; + + // Set the editors selection based on the current viewer's selection. + // + setSelection(currentViewer == null ? StructuredSelection.EMPTY : currentViewer.getSelection()); + } + } + + /** + * This returns the viewer as required by the {@link IViewerProvider} interface. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Viewer getViewer() + { + return currentViewer; + } + + /** + * This creates a context menu for the viewer and adds a listener as well registering the menu for extension. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void createContextMenuFor(StructuredViewer viewer) + { + MenuManager contextMenu = new MenuManager("#PopUp"); //$NON-NLS-1$ + contextMenu.add(new Separator("additions")); //$NON-NLS-1$ + contextMenu.setRemoveAllWhenShown(true); + contextMenu.addMenuListener(this); + Menu menu = contextMenu.createContextMenu(viewer.getControl()); + viewer.getControl().setMenu(menu); + getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer)); + + int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK; + Transfer[] transfers = new Transfer[] { LocalTransfer.getInstance() }; + viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(viewer)); + viewer.addDropSupport(dndOperations, transfers, new EditingDomainViewerDropAdapter(editingDomain, viewer)); + } + + /** + * This is the method called to load a resource into the editing domain's resource set based on the editor's input. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createModel() + { + URI resourceURI = EditUIUtil.getURI(getEditorInput()); + Exception exception = null; + Resource resource = null; + try + { + // Load the resource through the editing domain. + // + resource = editingDomain.getResourceSet().getResource(resourceURI, true); + } + catch (Exception e) + { + exception = e; + resource = editingDomain.getResourceSet().getResource(resourceURI, false); + } + + Diagnostic diagnostic = analyzeResourceProblems(resource, exception); + if (diagnostic.getSeverity() != Diagnostic.OK) + { + resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); + } + editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter); + } + + /** + * Returns a diagnostic describing the errors and warnings listed in the resource + * and the specified exception (if any). + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) + { + if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) + { + BasicDiagnostic basicDiagnostic = new BasicDiagnostic(Diagnostic.ERROR, "org.eclipse.emf.cdo.security.editor", //$NON-NLS-1$ + 0, getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$ + new Object[] { exception == null ? (Object)resource : exception }); + basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true)); + return basicDiagnostic; + } + else if (exception != null) + { + return new BasicDiagnostic(Diagnostic.ERROR, "org.eclipse.emf.cdo.security.editor", //$NON-NLS-1$ + 0, getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$ + new Object[] { exception }); + } + else + { + return Diagnostic.OK_INSTANCE; + } + } + + /** + * This is the method used by the framework to install your own controls. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void createPages() + { + // Creates the model from the editor input + // + createModel(); + + // Only creates the other pages if there is something that can be edited + // + if (!getEditingDomain().getResourceSet().getResources().isEmpty()) + { + // Create a page for the selection tree view. + // + Tree tree = new Tree(getContainer(), SWT.MULTI); + selectionViewer = new TreeViewer(tree); + setCurrentViewer(selectionViewer); + + selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); + selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider.FontAndColorProvider(adapterFactory, + selectionViewer)); + selectionViewer.setInput(editingDomain.getResourceSet()); + selectionViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true); + + new AdapterFactoryTreeEditor(selectionViewer.getTree(), adapterFactory); + + createContextMenuFor(selectionViewer); + int pageIndex = addPage(tree); + setPageText(pageIndex, getString("_UI_SelectionPage_label")); //$NON-NLS-1$ + + getSite().getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + setActivePage(0); + } + }); + } + + // Ensures that this editor will only display the page's tab + // area if there are more than one page + // + getContainer().addControlListener(new ControlAdapter() + { + boolean guard = false; + + @Override + public void controlResized(ControlEvent event) + { + if (!guard) + { + guard = true; + hideTabs(); + guard = false; + } + } + }); + + getSite().getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + updateProblemIndication(); + } + }); + } + + /** + * If there is just one page in the multi-page editor part, + * this hides the single tab at the bottom. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void hideTabs() + { + if (getPageCount() <= 1) + { + setPageText(0, ""); //$NON-NLS-1$ + if (getContainer() instanceof CTabFolder) + { + ((CTabFolder)getContainer()).setTabHeight(1); + Point point = getContainer().getSize(); + getContainer().setSize(point.x, point.y + 6); + } + } + } + + /** + * If there is more than one page in the multi-page editor part, + * this shows the tabs at the bottom. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void showTabs() + { + if (getPageCount() > 1) + { + setPageText(0, getString("_UI_SelectionPage_label")); //$NON-NLS-1$ + if (getContainer() instanceof CTabFolder) + { + ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT); + Point point = getContainer().getSize(); + getContainer().setSize(point.x, point.y - 6); + } + } + } + + /** + * This is used to track the active viewer. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected void pageChange(int pageIndex) + { + super.pageChange(pageIndex); + + if (contentOutlinePage != null) + { + handleContentOutlineSelection(contentOutlinePage.getSelection()); + } + } + + /** + * This is how the framework determines which interfaces we implement. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("rawtypes") + @Override + public Object getAdapter(Class key) + { + if (key.equals(IContentOutlinePage.class)) + { + return showOutlineView() ? getContentOutlinePage() : null; + } + else if (key.equals(IPropertySheetPage.class)) + { + return getPropertySheetPage(); + } + else if (key.equals(IGotoMarker.class)) + { + return this; + } + else + { + return super.getAdapter(key); + } + } + + /** + * This accesses a cached version of the content outliner. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IContentOutlinePage getContentOutlinePage() + { + if (contentOutlinePage == null) + { + // The content outline is just a tree. + // + class MyContentOutlinePage extends ContentOutlinePage + { + @Override + public void createControl(Composite parent) + { + super.createControl(parent); + contentOutlineViewer = getTreeViewer(); + contentOutlineViewer.addSelectionChangedListener(this); + + // Set up the tree viewer. + // + contentOutlineViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory)); + contentOutlineViewer.setLabelProvider(new AdapterFactoryLabelProvider.FontAndColorProvider(adapterFactory, + contentOutlineViewer)); + contentOutlineViewer.setInput(editingDomain.getResourceSet()); + + // Make sure our popups work. + // + createContextMenuFor(contentOutlineViewer); + + if (!editingDomain.getResourceSet().getResources().isEmpty()) + { + // Select the root object in the view. + // + contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources() + .get(0)), true); + } + } + + @Override + public void makeContributions(IMenuManager menuManager, IToolBarManager toolBarManager, + IStatusLineManager statusLineManager) + { + super.makeContributions(menuManager, toolBarManager, statusLineManager); + contentOutlineStatusLineManager = statusLineManager; + } + + @Override + public void setActionBars(IActionBars actionBars) + { + super.setActionBars(actionBars); + getActionBarContributor().shareGlobalActions(this, actionBars); + } + } + + contentOutlinePage = new MyContentOutlinePage(); + + // Listen to selection so that we can handle it is a special way. + // + contentOutlinePage.addSelectionChangedListener(new ISelectionChangedListener() + { + // This ensures that we handle selections correctly. + // + public void selectionChanged(SelectionChangedEvent event) + { + handleContentOutlineSelection(event.getSelection()); + } + }); + } + + return contentOutlinePage; + } + + /** + * This accesses a cached version of the property sheet. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IPropertySheetPage getPropertySheetPage() + { + if (propertySheetPage == null) + { + propertySheetPage = new ExtendedPropertySheetPage(editingDomain) + { + @Override + public void setSelectionToViewer(List<?> selection) + { + SecurityEditor.this.setSelectionToViewer(selection); + SecurityEditor.this.setFocus(); + } + + @Override + public void setActionBars(IActionBars actionBars) + { + super.setActionBars(actionBars); + getActionBarContributor().shareGlobalActions(this, actionBars); + } + }; + propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory)); + } + + return propertySheetPage; + } + + /** + * This deals with how we want selection in the outliner to affect the other views. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void handleContentOutlineSelection(ISelection selection) + { + if (selectionViewer != null && !selection.isEmpty() && selection instanceof IStructuredSelection) + { + Iterator<?> selectedElements = ((IStructuredSelection)selection).iterator(); + if (selectedElements.hasNext()) + { + // Get the first selected element. + // + Object selectedElement = selectedElements.next(); + + ArrayList<Object> selectionList = new ArrayList<Object>(); + selectionList.add(selectedElement); + while (selectedElements.hasNext()) + { + selectionList.add(selectedElements.next()); + } + + // Set the selection to the widget. + // + selectionViewer.setSelection(new StructuredSelection(selectionList)); + } + } + } + + /** + * This is for implementing {@link IEditorPart} and simply tests the command stack. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean isDirty() + { + return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded(); + } + + /** + * This is for implementing {@link IEditorPart} and simply saves the model file. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void doSave(IProgressMonitor progressMonitor) + { + // Save only resources that have actually changed. + // + final Map<Object, Object> saveOptions = new HashMap<Object, Object>(); + saveOptions.put(Resource.OPTION_SAVE_ONLY_IF_CHANGED, Resource.OPTION_SAVE_ONLY_IF_CHANGED_MEMORY_BUFFER); + + // Do the work within an operation because this is a long running activity that modifies the workbench. + // + WorkspaceModifyOperation operation = new WorkspaceModifyOperation() + { + // This is the method that gets invoked when the operation runs. + // + @Override + public void execute(IProgressMonitor monitor) + { + // Save the resources to the file system. + // + boolean first = true; + for (Resource resource : editingDomain.getResourceSet().getResources()) + { + if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) + && !editingDomain.isReadOnly(resource)) + { + try + { + long timeStamp = resource.getTimeStamp(); + resource.save(saveOptions); + if (resource.getTimeStamp() != timeStamp) + { + savedResources.add(resource); + } + } + catch (Exception exception) + { + resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception)); + } + first = false; + } + } + } + }; + + updateProblemIndication = false; + try + { + // This runs the options, and shows progress. + // + new ProgressMonitorDialog(getSite().getShell()).run(true, false, operation); + + // Refresh the necessary state. + // + ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone(); + firePropertyChange(IEditorPart.PROP_DIRTY); + } + catch (Exception exception) + { + // Something went wrong that shouldn't. + // + SecurityEditorPlugin.INSTANCE.log(exception); + } + updateProblemIndication = true; + updateProblemIndication(); + } + + /** + * This returns whether something has been persisted to the URI of the specified resource. + * The implementation uses the URI converter from the editor's resource set to try to open an input stream. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected boolean isPersisted(Resource resource) + { + boolean result = false; + try + { + InputStream stream = editingDomain.getResourceSet().getURIConverter().createInputStream(resource.getURI()); + if (stream != null) + { + result = true; + stream.close(); + } + } + catch (IOException e) + { + // Ignore + } + return result; + } + + /** + * This always returns true because it is not currently supported. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean isSaveAsAllowed() + { + return true; + } + + /** + * This also changes the editor's input. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void doSaveAs() + { + SaveAsDialog saveAsDialog = new SaveAsDialog(getSite().getShell()); + saveAsDialog.open(); + IPath path = saveAsDialog.getResult(); + if (path != null) + { + IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path); + if (file != null) + { + doSaveAs(URI.createPlatformResourceURI(file.getFullPath().toString(), true), new FileEditorInput(file)); + } + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected void doSaveAs(URI uri, IEditorInput editorInput) + { + editingDomain.getResourceSet().getResources().get(0).setURI(uri); + setInputWithNotify(editorInput); + setPartName(editorInput.getName()); + IProgressMonitor progressMonitor = getActionBars().getStatusLineManager() != null ? getActionBars() + .getStatusLineManager().getProgressMonitor() : new NullProgressMonitor(); + doSave(progressMonitor); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void gotoMarker(IMarker marker) + { + try + { + if (marker.getType().equals(EValidator.MARKER)) + { + String uriAttribute = marker.getAttribute(EValidator.URI_ATTRIBUTE, null); + if (uriAttribute != null) + { + URI uri = URI.createURI(uriAttribute); + EObject eObject = editingDomain.getResourceSet().getEObject(uri, true); + if (eObject != null) + { + setSelectionToViewer(Collections.singleton(editingDomain.getWrapper(eObject))); + } + } + } + } + catch (CoreException exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + } + + /** + * This is called during startup. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void init(IEditorSite site, IEditorInput editorInput) + { + setSite(site); + setInputWithNotify(editorInput); + setPartName(editorInput.getName()); + site.setSelectionProvider(this); + site.getPage().addPartListener(partListener); + ResourcesPlugin.getWorkspace().addResourceChangeListener(resourceChangeListener, IResourceChangeEvent.POST_CHANGE); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void setFocus() + { + getControl(getActivePage()).setFocus(); + } + + /** + * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void addSelectionChangedListener(ISelectionChangedListener listener) + { + selectionChangedListeners.add(listener); + } + + /** + * This implements {@link org.eclipse.jface.viewers.ISelectionProvider}. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void removeSelectionChangedListener(ISelectionChangedListener listener) + { + selectionChangedListeners.remove(listener); + } + + /** + * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public ISelection getSelection() + { + return editorSelection; + } + + /** + * This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to set this editor's overall selection. + * Calling this result will notify the listeners. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setSelection(ISelection selection) + { + editorSelection = selection; + + for (ISelectionChangedListener listener : selectionChangedListeners) + { + listener.selectionChanged(new SelectionChangedEvent(this, selection)); + } + setStatusLineManager(selection); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setStatusLineManager(ISelection selection) + { + IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ? contentOutlineStatusLineManager + : getActionBars().getStatusLineManager(); + + if (statusLineManager != null) + { + if (selection instanceof IStructuredSelection) + { + Collection<?> collection = ((IStructuredSelection)selection).toList(); + switch (collection.size()) + { + case 0: + { + statusLineManager.setMessage(getString("_UI_NoObjectSelected")); //$NON-NLS-1$ + break; + } + case 1: + { + String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next()); + statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text)); //$NON-NLS-1$ + break; + } + default: + { + statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size()))); //$NON-NLS-1$ + break; + } + } + } + else + { + statusLineManager.setMessage(""); //$NON-NLS-1$ + } + } + } + + /** + * This looks up a string in the plugin's plugin.properties file. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static String getString(String key) + { + return SecurityEditorPlugin.INSTANCE.getString(key); + } + + /** + * This looks up a string in plugin.properties, making a substitution. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static String getString(String key, Object s1) + { + return SecurityEditorPlugin.INSTANCE.getString(key, new Object[] { s1 }); + } + + /** + * This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void menuAboutToShow(IMenuManager menuManager) + { + ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EditingDomainActionBarContributor getActionBarContributor() + { + return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IActionBars getActionBars() + { + return getActionBarContributor().getActionBars(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public AdapterFactory getAdapterFactory() + { + return adapterFactory; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void dispose() + { + updateProblemIndication = false; + + ResourcesPlugin.getWorkspace().removeResourceChangeListener(resourceChangeListener); + + getSite().getPage().removePartListener(partListener); + + adapterFactory.dispose(); + + if (getActionBarContributor().getActiveEditor() == this) + { + getActionBarContributor().setActiveEditor(null); + } + + if (propertySheetPage != null) + { + propertySheetPage.dispose(); + } + + if (contentOutlinePage != null) + { + contentOutlinePage.dispose(); + } + + super.dispose(); + } + + /** + * Returns whether the outline view should be presented to the user. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected boolean showOutlineView() + { + return false; + } +} diff --git a/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditorPlugin.java b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditorPlugin.java new file mode 100644 index 0000000000..d8c2625eee --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityEditorPlugin.java @@ -0,0 +1,104 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.presentation; + +import org.eclipse.emf.cdo.edit.CDOEditPlugin; + +import org.eclipse.emf.common.EMFPlugin; +import org.eclipse.emf.common.ui.EclipseUIPlugin; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; + +/** + * This is the central singleton for the Security editor plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public final class SecurityEditorPlugin extends EMFPlugin +{ + /** + * Keep track of the singleton. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static final SecurityEditorPlugin INSTANCE = new SecurityEditorPlugin(); + + /** + * Keep track of the singleton. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static Implementation plugin; + + /** + * Create the instance. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityEditorPlugin() + { + super(new ResourceLocator[] { EcoreEditPlugin.INSTANCE, CDOEditPlugin.INSTANCE, }); + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the singleton instance. + * @generated + */ + @Override + public ResourceLocator getPluginResourceLocator() + { + return plugin; + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the singleton instance. + * @generated + */ + public static Implementation getPlugin() + { + return plugin; + } + + /** + * The actual implementation of the Eclipse <b>Plugin</b>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static class Implementation extends EclipseUIPlugin + { + /** + * Creates an instance. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Implementation() + { + super(); + + // Remember the static instance. + // + plugin = this; + } + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityModelWizard.java b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityModelWizard.java new file mode 100644 index 0000000000..0267732423 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security.editor/src/org/eclipse/emf/cdo/security/presentation/SecurityModelWizard.java @@ -0,0 +1,671 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.presentation; + +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.provider.SecurityEditPlugin; + +import org.eclipse.emf.common.CommonPlugin; +import org.eclipse.emf.common.util.URI; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EClassifier; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.resource.Resource; +import org.eclipse.emf.ecore.resource.ResourceSet; +import org.eclipse.emf.ecore.resource.impl.ResourceSetImpl; +import org.eclipse.emf.ecore.xmi.XMLResource; +import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry; + +import org.eclipse.core.resources.IContainer; +import org.eclipse.core.resources.IFile; +import org.eclipse.core.resources.IFolder; +import org.eclipse.core.resources.IProject; +import org.eclipse.core.resources.IResource; +import org.eclipse.core.resources.ResourcesPlugin; +import org.eclipse.core.runtime.IProgressMonitor; +import org.eclipse.core.runtime.Path; +import org.eclipse.jface.dialogs.MessageDialog; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.viewers.StructuredSelection; +import org.eclipse.jface.wizard.Wizard; +import org.eclipse.jface.wizard.WizardPage; +import org.eclipse.swt.SWT; +import org.eclipse.swt.events.ModifyEvent; +import org.eclipse.swt.events.ModifyListener; +import org.eclipse.swt.layout.GridData; +import org.eclipse.swt.layout.GridLayout; +import org.eclipse.swt.widgets.Combo; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Label; +import org.eclipse.ui.INewWizard; +import org.eclipse.ui.IWorkbench; +import org.eclipse.ui.IWorkbenchPage; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.IWorkbenchWindow; +import org.eclipse.ui.PartInitException; +import org.eclipse.ui.actions.WorkspaceModifyOperation; +import org.eclipse.ui.dialogs.WizardNewFileCreationPage; +import org.eclipse.ui.part.FileEditorInput; +import org.eclipse.ui.part.ISetSelectionTarget; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.MissingResourceException; +import java.util.StringTokenizer; + +/** + * This is a simple wizard for creating a new model file. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ +public class SecurityModelWizard extends Wizard implements INewWizard +{ + /** + * The supported extensions for created files. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static final List<String> FILE_EXTENSIONS = Collections.unmodifiableList(Arrays + .asList(SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityEditorFilenameExtensions").split("\\s*,\\s*"))); //$NON-NLS-1$ //$NON-NLS-2$ + + /** + * A formatted list of supported file extensions, suitable for display. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static final String FORMATTED_FILE_EXTENSIONS = SecurityEditorPlugin.INSTANCE.getString( + "_UI_SecurityEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", "); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + + /** + * This caches an instance of the model package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityPackage securityPackage = SecurityPackage.eINSTANCE; + + /** + * This caches an instance of the model factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityFactory securityFactory = securityPackage.getSecurityFactory(); + + /** + * This is the file creation page. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityModelWizardNewFileCreationPage newFileCreationPage; + + /** + * This is the initial object creation page. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityModelWizardInitialObjectCreationPage initialObjectCreationPage; + + /** + * Remember the selection during initialization for populating the default container. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IStructuredSelection selection; + + /** + * Remember the workbench during initialization. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected IWorkbench workbench; + + /** + * Caches the names of the types that can be created as the root object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected List<String> initialObjectNames; + + /** + * This just records the information. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void init(IWorkbench workbench, IStructuredSelection selection) + { + this.workbench = workbench; + this.selection = selection; + setWindowTitle(SecurityEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); //$NON-NLS-1$ + setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE.getImageDescriptor(SecurityEditorPlugin.INSTANCE + .getImage("full/wizban/NewSecurity"))); //$NON-NLS-1$ + } + + /** + * Returns the names of the types that can be created as the root object. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<String> getInitialObjectNames() + { + if (initialObjectNames == null) + { + initialObjectNames = new ArrayList<String>(); + for (EClassifier eClassifier : securityPackage.getEClassifiers()) + { + if (eClassifier instanceof EClass) + { + EClass eClass = (EClass)eClassifier; + if (!eClass.isAbstract()) + { + initialObjectNames.add(eClass.getName()); + } + } + } + Collections.sort(initialObjectNames, CommonPlugin.INSTANCE.getComparator()); + } + return initialObjectNames; + } + + /** + * Create a new model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected EObject createInitialModel() + { + EClass eClass = (EClass)securityPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName()); + EObject rootObject = securityFactory.create(eClass); + return rootObject; + } + + /** + * Do the work after everything is specified. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public boolean performFinish() + { + try + { + // Remember the file. + // + final IFile modelFile = getModelFile(); + + // Do the work within an operation. + // + WorkspaceModifyOperation operation = new WorkspaceModifyOperation() + { + @Override + protected void execute(IProgressMonitor progressMonitor) + { + try + { + // Create a resource set + // + ResourceSet resourceSet = new ResourceSetImpl(); + + // Get the URI of the model file. + // + URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true); + + // Create a resource for this file. + // + Resource resource = resourceSet.createResource(fileURI); + + // Add the initial model object to the contents. + // + EObject rootObject = createInitialModel(); + if (rootObject != null) + { + resource.getContents().add(rootObject); + } + + // Save the contents of the resource to the file system. + // + Map<Object, Object> options = new HashMap<Object, Object>(); + options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding()); + resource.save(options); + } + catch (Exception exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + } + finally + { + progressMonitor.done(); + } + } + }; + + getContainer().run(false, false, operation); + + // Select the new file resource in the current view. + // + IWorkbenchWindow workbenchWindow = workbench.getActiveWorkbenchWindow(); + IWorkbenchPage page = workbenchWindow.getActivePage(); + final IWorkbenchPart activePart = page.getActivePart(); + if (activePart instanceof ISetSelectionTarget) + { + final ISelection targetSelection = new StructuredSelection(modelFile); + getShell().getDisplay().asyncExec(new Runnable() + { + public void run() + { + ((ISetSelectionTarget)activePart).selectReveal(targetSelection); + } + }); + } + + // Open an editor on the new file. + // + try + { + page.openEditor(new FileEditorInput(modelFile), + workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId()); + } + catch (PartInitException exception) + { + MessageDialog.openError(workbenchWindow.getShell(), + SecurityEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage()); //$NON-NLS-1$ + return false; + } + + return true; + } + catch (Exception exception) + { + SecurityEditorPlugin.INSTANCE.log(exception); + return false; + } + } + + /** + * This is the one page of the wizard. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public class SecurityModelWizardNewFileCreationPage extends WizardNewFileCreationPage + { + /** + * Pass in the selection. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) + { + super(pageId, selection); + } + + /** + * The framework calls this to see if the file is correct. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected boolean validatePage() + { + if (super.validatePage()) + { + String extension = new Path(getFileName()).getFileExtension(); + if (extension == null || !FILE_EXTENSIONS.contains(extension)) + { + String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; //$NON-NLS-1$ //$NON-NLS-2$ + setErrorMessage(SecurityEditorPlugin.INSTANCE.getString(key, new Object[] { FORMATTED_FILE_EXTENSIONS })); + return false; + } + return true; + } + return false; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IFile getModelFile() + { + return ResourcesPlugin.getWorkspace().getRoot().getFile(getContainerFullPath().append(getFileName())); + } + } + + /** + * This is the page where the type of object to create is selected. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public class SecurityModelWizardInitialObjectCreationPage extends WizardPage + { + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Combo initialObjectField; + + /** + * @generated + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + */ + protected List<String> encodings; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Combo encodingField; + + /** + * Pass in the selection. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityModelWizardInitialObjectCreationPage(String pageId) + { + super(pageId); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createControl(Composite parent) + { + Composite composite = new Composite(parent, SWT.NONE); + { + GridLayout layout = new GridLayout(); + layout.numColumns = 1; + layout.verticalSpacing = 12; + composite.setLayout(layout); + + GridData data = new GridData(); + data.verticalAlignment = GridData.FILL; + data.grabExcessVerticalSpace = true; + data.horizontalAlignment = GridData.FILL; + composite.setLayoutData(data); + } + + Label containerLabel = new Label(composite, SWT.LEFT); + { + containerLabel.setText(SecurityEditorPlugin.INSTANCE.getString("_UI_ModelObject")); //$NON-NLS-1$ + + GridData data = new GridData(); + data.horizontalAlignment = GridData.FILL; + containerLabel.setLayoutData(data); + } + + initialObjectField = new Combo(composite, SWT.BORDER); + { + GridData data = new GridData(); + data.horizontalAlignment = GridData.FILL; + data.grabExcessHorizontalSpace = true; + initialObjectField.setLayoutData(data); + } + + for (String objectName : getInitialObjectNames()) + { + initialObjectField.add(getLabel(objectName)); + } + + if (initialObjectField.getItemCount() == 1) + { + initialObjectField.select(0); + } + initialObjectField.addModifyListener(validator); + + Label encodingLabel = new Label(composite, SWT.LEFT); + { + encodingLabel.setText(SecurityEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); //$NON-NLS-1$ + + GridData data = new GridData(); + data.horizontalAlignment = GridData.FILL; + encodingLabel.setLayoutData(data); + } + encodingField = new Combo(composite, SWT.BORDER); + { + GridData data = new GridData(); + data.horizontalAlignment = GridData.FILL; + data.grabExcessHorizontalSpace = true; + encodingField.setLayoutData(data); + } + + for (String encoding : getEncodings()) + { + encodingField.add(encoding); + } + + encodingField.select(0); + encodingField.addModifyListener(validator); + + setPageComplete(validatePage()); + setControl(composite); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected ModifyListener validator = new ModifyListener() + { + public void modifyText(ModifyEvent e) + { + setPageComplete(validatePage()); + } + }; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected boolean validatePage() + { + return getInitialObjectName() != null && getEncodings().contains(encodingField.getText()); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void setVisible(boolean visible) + { + super.setVisible(visible); + if (visible) + { + if (initialObjectField.getItemCount() == 1) + { + initialObjectField.clearSelection(); + encodingField.setFocus(); + } + else + { + encodingField.clearSelection(); + initialObjectField.setFocus(); + } + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getInitialObjectName() + { + String label = initialObjectField.getText(); + + for (String name : getInitialObjectNames()) + { + if (getLabel(name).equals(label)) + { + return name; + } + } + return null; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getEncoding() + { + return encodingField.getText(); + } + + /** + * Returns the label for the specified type name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected String getLabel(String typeName) + { + try + { + return SecurityEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type"); //$NON-NLS-1$ //$NON-NLS-2$ + } + catch (MissingResourceException mre) + { + SecurityEditorPlugin.INSTANCE.log(mre); + } + return typeName; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected Collection<String> getEncodings() + { + if (encodings == null) + { + encodings = new ArrayList<String>(); + for (StringTokenizer stringTokenizer = new StringTokenizer( + SecurityEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) //$NON-NLS-1$ + { + encodings.add(stringTokenizer.nextToken()); + } + } + return encodings; + } + } + + /** + * The framework calls this to create the contents of the wizard. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public void addPages() + { + // Create a page, set the title, and the initial model file name. + // + newFileCreationPage = new SecurityModelWizardNewFileCreationPage("Whatever", selection); //$NON-NLS-1$ + newFileCreationPage.setTitle(SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityModelWizard_label")); //$NON-NLS-1$ + newFileCreationPage.setDescription(SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityModelWizard_description")); //$NON-NLS-1$ + newFileCreationPage + .setFileName(SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); //$NON-NLS-1$ //$NON-NLS-2$ + addPage(newFileCreationPage); + + // Try and get the resource selection to determine a current directory for the file dialog. + // + if (selection != null && !selection.isEmpty()) + { + // Get the resource... + // + Object selectedElement = selection.iterator().next(); + if (selectedElement instanceof IResource) + { + // Get the resource parent, if its a file. + // + IResource selectedResource = (IResource)selectedElement; + if (selectedResource.getType() == IResource.FILE) + { + selectedResource = selectedResource.getParent(); + } + + // This gives us a directory... + // + if (selectedResource instanceof IFolder || selectedResource instanceof IProject) + { + // Set this for the container. + // + newFileCreationPage.setContainerFullPath(selectedResource.getFullPath()); + + // Make up a unique new name here. + // + String defaultModelBaseFilename = SecurityEditorPlugin.INSTANCE + .getString("_UI_SecurityEditorFilenameDefaultBase"); //$NON-NLS-1$ + String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0); + String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension; //$NON-NLS-1$ + for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) + { + modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension; //$NON-NLS-1$ + } + newFileCreationPage.setFileName(modelFilename); + } + } + } + initialObjectCreationPage = new SecurityModelWizardInitialObjectCreationPage("Whatever2"); //$NON-NLS-1$ + initialObjectCreationPage.setTitle(SecurityEditorPlugin.INSTANCE.getString("_UI_SecurityModelWizard_label")); //$NON-NLS-1$ + initialObjectCreationPage.setDescription(SecurityEditorPlugin.INSTANCE + .getString("_UI_Wizard_initial_object_description")); //$NON-NLS-1$ + addPage(initialObjectCreationPage); + } + + /** + * Get the file from the page. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public IFile getModelFile() + { + return newFileCreationPage.getModelFile(); + } + +} diff --git a/plugins/org.eclipse.emf.cdo.security/.classpath b/plugins/org.eclipse.emf.cdo.security/.classpath new file mode 100644 index 0000000000..64c5e31b7a --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.classpath @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<classpath> + <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/> + <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> + <classpathentry kind="src" path="src"/> + <classpathentry kind="output" path="bin"/> +</classpath> diff --git a/plugins/org.eclipse.emf.cdo.security/.options b/plugins/org.eclipse.emf.cdo.security/.options new file mode 100644 index 0000000000..0d1228fbd6 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.options @@ -0,0 +1,3 @@ +# Debugging and tracing options + +org.eclipse.emf.cdo.security/debug = true diff --git a/plugins/org.eclipse.emf.cdo.security/.project b/plugins/org.eclipse.emf.cdo.security/.project new file mode 100644 index 0000000000..0db6821506 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.project @@ -0,0 +1,44 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.emf.cdo.security</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.ManifestBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.SchemaBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.emf.cdo.releng.version.VersionBuilder</name> + <arguments> + <dictionary> + <key>release.path</key> + <value>/org.eclipse.emf.cdo.releng/release.xml</value> + </dictionary> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.pde.PluginNature</nature> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature> + <nature>org.eclipse.emf.cdo.releng.version.VersionNature</nature> + </natures> +</projectDescription> diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.core.resources.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 0000000000..8085bb7dc7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,4 @@ +eclipse.preferences.version=1 +encoding//model/org.eclipse.emf.cdo.defs.ecorediag=UTF-8 +encoding//model/security.ecore=UTF-8 +encoding//model/security.ecorediag=UTF-8 diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..1fa0d45db9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,413 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.cleanOutputFolder=clean +org.eclipse.jdt.core.builder.duplicateResourceTask=warning +org.eclipse.jdt.core.builder.invalidClasspath=abort +org.eclipse.jdt.core.builder.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch,*.ucls,doc-files/,package.html,package-info.java +org.eclipse.jdt.core.circularClasspath=error +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.codeComplete.argumentPrefixes= +org.eclipse.jdt.core.codeComplete.argumentSuffixes= +org.eclipse.jdt.core.codeComplete.fieldPrefixes= +org.eclipse.jdt.core.codeComplete.fieldSuffixes= +org.eclipse.jdt.core.codeComplete.localPrefixes= +org.eclipse.jdt.core.codeComplete.localSuffixes= +org.eclipse.jdt.core.codeComplete.staticFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFieldSuffixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes= +org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes= +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault +org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable +org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.5 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.doc.comment.support=enabled +org.eclipse.jdt.core.compiler.maxProblemPerUnit=100 +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=warning +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore +org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=disabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=warning +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning +org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=warning +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=warning +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unclosedCloseable=ignore +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.source=1.5 +org.eclipse.jdt.core.compiler.taskCaseSensitive=enabled +org.eclipse.jdt.core.compiler.taskPriorities=NORMAL,HIGH,HIGH,LOW,LOW,LOW,LOW,LOW +org.eclipse.jdt.core.compiler.taskTags=TODO,FIXME,XXX,PERF,MEM,POLISH,@generated NOT,@ADDED +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 +org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=1 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 +org.eclipse.jdt.core.formatter.blank_lines_before_method=1 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 +org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=next_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=next_line +org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=next_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=next_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=next_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=next_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=true +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=true +org.eclipse.jdt.core.formatter.comment.format_block_comments=true +org.eclipse.jdt.core.formatter.comment.format_header=false +org.eclipse.jdt.core.formatter.comment.format_html=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false +org.eclipse.jdt.core.formatter.comment.format_line_comments=true +org.eclipse.jdt.core.formatter.comment.format_source_code=true +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true +org.eclipse.jdt.core.formatter.comment.indent_root_tags=true +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert +org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert +org.eclipse.jdt.core.formatter.comment.line_length=120 +org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true +org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true +org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off +org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false +org.eclipse.jdt.core.formatter.indentation.size=2 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_member=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.join_lines_in_comments=true +org.eclipse.jdt.core.formatter.join_wrapped_lines=true +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.formatter.lineSplit=120 +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true +org.eclipse.jdt.core.formatter.tabulation.char=space +org.eclipse.jdt.core.formatter.tabulation.size=2 +org.eclipse.jdt.core.formatter.use_on_off_tags=false +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true +org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=ignore +org.eclipse.jdt.core.incompleteClasspath=error diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.launching.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.launching.prefs new file mode 100644 index 0000000000..556ed07a3c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.launching.prefs @@ -0,0 +1,3 @@ +#Fri Sep 02 05:38:34 CEST 2011 +eclipse.preferences.version=1 +org.eclipse.jdt.launching.PREF_STRICTLY_COMPATIBLE_JRE_NOT_AVAILABLE=ignore diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.ui.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 0000000000..4343e2f963 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,119 @@ +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.always_use_blocks=true +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.convert_to_enhanced_for_loop=false +cleanup.correct_indentation=true +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=false +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=false +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.organize_imports=true +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.remove_private_constructors=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_private_fields=true +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=true +cleanup.remove_unused_private_types=true +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.use_blocks=true +cleanup.use_blocks_only_for_return_and_throw=false +cleanup.use_parentheses_in_expressions=true +cleanup.use_this_for_non_static_field_access=true +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=true +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup_profile=_EMFT +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_EMFT +formatter_settings_version=12 +org.eclipse.jdt.ui.exception.name=ex +org.eclipse.jdt.ui.gettersetter.use.is=true +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=org.eclipse.emf.cdo;org.eclipse.emf.internal.cdo;org.eclipse.net4j;org.eclipse.internal.net4j;org.eclipse.emf;org.eclipse;com;org;javax;java; +org.eclipse.jdt.ui.javadoc=true +org.eclipse.jdt.ui.keywordthis=false +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.overrideannotation=true +org.eclipse.jdt.ui.staticondemandthreshold=99 +org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="false" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment"/><template autoinsert\="false" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment"/><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment"/><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*\r\n * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) and others.\r\n * All rights reserved. This program and the accompanying materials\r\n * are made available under the terms of the Eclipse Public License v1.0\r\n * which accompanies this distribution, and is available at\r\n * http\://www.eclipse.org/legal/epl-v10.html\r\n * \r\n * Contributors\:\r\n * Eike Stepper - initial API and implementation\r\n */</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\r\n * @author Eike Stepper\r\n */</template><template autoinsert\="false" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment"/><template autoinsert\="false" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment"/><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment"/><template autoinsert\="false" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment"/><template autoinsert\="true" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\r\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\r\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\r\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\r\n</template><template autoinsert\="false" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">${exception_var}.printStackTrace();</template><template autoinsert\="false" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">${body_statement}</template><template autoinsert\="false" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">${body_statement}</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></templates> +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=false +sp_cleanup.add_serial_version_id=false +sp_cleanup.always_use_blocks=true +sp_cleanup.always_use_parentheses_in_expressions=false +sp_cleanup.always_use_this_for_non_static_field_access=false +sp_cleanup.always_use_this_for_non_static_method_access=false +sp_cleanup.convert_to_enhanced_for_loop=false +sp_cleanup.correct_indentation=true +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.make_local_variable_final=false +sp_cleanup.make_parameters_final=false +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=false +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.organize_imports=true +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.remove_private_constructors=true +sp_cleanup.remove_trailing_whitespaces=true +sp_cleanup.remove_trailing_whitespaces_all=true +sp_cleanup.remove_trailing_whitespaces_ignore_empty=false +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_private_fields=true +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=true +sp_cleanup.remove_unused_private_types=true +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.use_blocks=true +sp_cleanup.use_blocks_only_for_return_and_throw=false +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_this_for_non_static_field_access=true +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=true +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.ltk.core.refactoring.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.ltk.core.refactoring.prefs new file mode 100644 index 0000000000..864e30fe5d --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.ltk.core.refactoring.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +org.eclipse.ltk.core.refactoring.enable.project.refactoring.history=false diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.tasks.ui.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.tasks.ui.prefs new file mode 100644 index 0000000000..b050639a54 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.tasks.ui.prefs @@ -0,0 +1,4 @@ +#Thu Feb 04 09:44:24 CET 2010 +eclipse.preferences.version=1 +project.repository.kind=bugzilla +project.repository.url=https\://bugs.eclipse.org/bugs diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.team.ui.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.team.ui.prefs new file mode 100644 index 0000000000..2f50f36c0c --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.mylyn.team.ui.prefs @@ -0,0 +1,3 @@ +#Thu Feb 04 09:44:24 CET 2010 +commit.comment.template=[${task.id}] ${task.description} \r\n${task.url} +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.api.tools.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.api.tools.prefs new file mode 100644 index 0000000000..f8d0a0660e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.api.tools.prefs @@ -0,0 +1,94 @@ +#Thu Feb 04 09:44:24 CET 2010 +ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error +ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error +ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error +API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error +CLASS_ELEMENT_TYPE_ADDED_METHOD=Error +CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error +CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error +CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error +CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error +ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error +ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error +ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +FIELD_ELEMENT_TYPE_ADDED_VALUE=Error +FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error +FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error +FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error +FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error +ILLEGAL_EXTEND=Warning +ILLEGAL_IMPLEMENT=Warning +ILLEGAL_INSTANTIATE=Warning +ILLEGAL_OVERRIDE=Warning +ILLEGAL_REFERENCE=Warning +INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error +INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error +INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error +INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error +INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error +INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error +INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +INVALID_JAVADOC_TAG=Ignore +INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Ignore +LEAK_EXTEND=Warning +LEAK_FIELD_DECL=Warning +LEAK_IMPLEMENT=Warning +LEAK_METHOD_PARAM=Warning +LEAK_METHOD_RETURN_TYPE=Warning +METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error +METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error +METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error +METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error +METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error +METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error +METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error +TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error +UNUSED_PROBLEM_FILTERS=Ignore +automatically_removed_unused_problem_filters=Disabled +eclipse.preferences.version=1 +incompatible_api_component_version=Error +incompatible_api_component_version_include_major_without_breaking_change=Disabled +incompatible_api_component_version_include_minor_without_api_change=Disabled +invalid_since_tag_version=Error +malformed_since_tag=Error +missing_since_tag=Error +report_api_breakage_when_major_version_incremented=Disabled +report_resolution_errors_api_component=Warning diff --git a/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.prefs b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.prefs new file mode 100644 index 0000000000..c6b96bb45e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/.settings/org.eclipse.pde.prefs @@ -0,0 +1,31 @@ +#Thu Feb 04 09:44:24 CET 2010 +compilers.f.unresolved-features=1 +compilers.f.unresolved-plugins=1 +compilers.incompatible-environment=1 +compilers.p.build=1 +compilers.p.build.bin.includes=1 +compilers.p.build.java.compliance=1 +compilers.p.build.missing.output=2 +compilers.p.build.output.library=1 +compilers.p.build.source.library=1 +compilers.p.build.src.includes=1 +compilers.p.deprecated=1 +compilers.p.discouraged-class=1 +compilers.p.internal=1 +compilers.p.missing-packages=1 +compilers.p.missing-version-export-package=1 +compilers.p.missing-version-import-package=1 +compilers.p.missing-version-require-bundle=1 +compilers.p.no-required-att=0 +compilers.p.not-externalized-att=2 +compilers.p.unknown-attribute=1 +compilers.p.unknown-class=1 +compilers.p.unknown-element=1 +compilers.p.unknown-identifier=1 +compilers.p.unknown-resource=1 +compilers.p.unresolved-ex-points=0 +compilers.p.unresolved-import=0 +compilers.s.create-docs=false +compilers.s.doc-folder=doc +compilers.s.open-tags=1 +eclipse.preferences.version=1 diff --git a/plugins/org.eclipse.emf.cdo.security/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.cdo.security/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..a0024849f6 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/META-INF/MANIFEST.MF @@ -0,0 +1,15 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: %pluginName +Bundle-SymbolicName: org.eclipse.emf.cdo.security;singleton:=true +Bundle-Version: 4.1.0.qualifier +Bundle-ClassPath: . +Bundle-Vendor: %providerName +Bundle-Localization: plugin +Bundle-RequiredExecutionEnvironment: J2SE-1.5 +Export-Package: org.eclipse.emf.cdo.security;version="4.1.0", + org.eclipse.emf.cdo.security.impl;version="4.1.0", + org.eclipse.emf.cdo.security.util;version="4.1.0" +Require-Bundle: org.eclipse.core.runtime;bundle-version="[3.4.0,4.0.0)", + org.eclipse.emf.cdo;bundle-version="[4.1.0,5.0.0)";visibility:=reexport +Bundle-ActivationPolicy: lazy diff --git a/plugins/org.eclipse.emf.cdo.security/about.html b/plugins/org.eclipse.emf.cdo.security/about.html new file mode 100644 index 0000000000..d35d5aed64 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 5, 2007</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise +indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html> diff --git a/plugins/org.eclipse.emf.cdo.security/build.properties b/plugins/org.eclipse.emf.cdo.security/build.properties new file mode 100644 index 0000000000..7113f16d6d --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/build.properties @@ -0,0 +1,14 @@ +# + +bin.includes = .,\ + model/,\ + META-INF/,\ + plugin.xml,\ + plugin.properties,\ + about.html,\ + copyright.txt +jars.compile.order = . +source.. = src/ +output.. = bin/ +src.includes = about.html,\ + copyright.txt diff --git a/plugins/org.eclipse.emf.cdo.security/copyright.txt b/plugins/org.eclipse.emf.cdo.security/copyright.txt new file mode 100644 index 0000000000..0a0f67e6d7 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/copyright.txt @@ -0,0 +1,8 @@ +Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation
\ No newline at end of file diff --git a/plugins/org.eclipse.emf.cdo.security/model/security.ecore b/plugins/org.eclipse.emf.cdo.security/model/security.ecore new file mode 100644 index 0000000000..ac6b3d4d68 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/model/security.ecore @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="security" nsURI="http://www.eclipse.org/emf/CDO/security/4.1.0" + nsPrefix="security"> + <eClassifiers xsi:type="ecore:EClass" name="SecurityElement" abstract="true" eSuperTypes="../../org.eclipse.emf.cdo/model/etypes.ecore#//ModelElement"> + <eOperations name="getRealm" lowerBound="1" eType="#//Realm"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="SecurityItem" abstract="true" eSuperTypes="#//SecurityElement"/> + <eClassifiers xsi:type="ecore:EClass" name="Realm" eSuperTypes="#//SecurityElement"> + <eStructuralFeatures xsi:type="ecore:EReference" name="items" upperBound="-1" + eType="#//SecurityItem" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Directory" eSuperTypes="#//SecurityItem"> + <eStructuralFeatures xsi:type="ecore:EReference" name="items" upperBound="-1" + eType="#//SecurityItem" containment="true"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Role" eSuperTypes="#//SecurityItem"> + <eStructuralFeatures xsi:type="ecore:EReference" name="assignees" upperBound="-1" + eType="#//Assignee" eOpposite="#//Assignee/roles"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="id" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="type" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Assignee" abstract="true" eSuperTypes="#//SecurityItem"> + <eStructuralFeatures xsi:type="ecore:EReference" name="roles" upperBound="-1" + eType="#//Role" eOpposite="#//Role/assignees"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="id" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Group" eSuperTypes="#//Assignee"> + <eStructuralFeatures xsi:type="ecore:EReference" name="inheritedGroups" upperBound="-1" + eType="#//Group" eOpposite="#//Group/inheritingGroups"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="inheritingGroups" upperBound="-1" + eType="#//Group" eOpposite="#//Group/inheritedGroups"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="users" upperBound="-1" + eType="#//User" eOpposite="#//User/groups"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="User" eSuperTypes="#//Assignee"> + <eStructuralFeatures xsi:type="ecore:EReference" name="groups" upperBound="-1" + eType="#//Group" eOpposite="#//Group/users"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="firstName" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="lastName" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="email" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="locked" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EBoolean"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="password" eType="#//UserPassword" + containment="true"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="UserPassword"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="encrypted" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eClassifiers> +</ecore:EPackage> diff --git a/plugins/org.eclipse.emf.cdo.security/model/security.ecorediag b/plugins/org.eclipse.emf.cdo.security/model/security.ecorediag new file mode 100644 index 0000000000..9fdfc768a2 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/model/security.ecorediag @@ -0,0 +1,326 @@ +<?xml version="1.0" encoding="UTF-8"?> +<notation:Diagram xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" xmlns:notation="http://www.eclipse.org/gmf/runtime/1.0.2/notation" xmi:id="_LqfpMaYxEeGAP_kHrioTcA" type="EcoreTools" name="security" measurementUnit="Pixel"> + <children xmi:type="notation:Node" xmi:id="_RJPJ0KYxEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_RLvrQKYxEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_RLzVoKYxEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_RLzVoaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_RLzVoqYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_RLzVo6YxEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_RL0jwKYxEeGAP_kHrioTcA" type="5002"> + <children xmi:type="notation:Node" xmi:id="_4mfh4KYyEeGAP_kHrioTcA" type="2002"> + <element xmi:type="ecore:EOperation" href="security.ecore#//SecurityElement/getRealm"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_4mfh4aYyEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:DrawerStyle" xmi:id="_RL0jwaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_RL0jwqYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_RL0jw6YxEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_RJPw4KYxEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//SecurityElement"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_RJPw4aYxEeGAP_kHrioTcA" x="145" y="30" width="198" height="63"/> + </children> + <children xmi:type="notation:Node" xmi:id="_glO9wKYxEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_glSBEKYxEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_glSoIKYxEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_glSoIaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_glSoIqYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_glSoI6YxEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_glSoJKYxEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_glTPMKYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_glTPMaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_glTPMqYxEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_glO9waYxEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//Realm"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_glO9wqYxEeGAP_kHrioTcA" x="77" y="151" width="126"/> + </children> + <children xmi:type="notation:Node" xmi:id="_kzdRsKYxEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_kzgVAKYxEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_kzg8EKYxEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_kzg8EaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_kzg8EqYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_kzg8E6YxEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_kzhjIKYxEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_kzhjIaYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_kzhjIqYxEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_kzhjI6YxEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_kzdRsaYxEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//User"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_kzdRsqYxEeGAP_kHrioTcA" x="214" y="391"/> + </children> + <children xmi:type="notation:Node" xmi:id="_0ZWzEKYyEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_0ZcSoKYyEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_0Zc5sKYyEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_0Zc5saYyEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_0Zc5sqYyEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_0Zc5s6YyEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_0ZdgwKYyEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_0ZdgwaYyEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_0ZdgwqYyEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_0Zdgw6YyEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_0ZWzEaYyEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//Group"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_0ZWzEqYyEeGAP_kHrioTcA" x="451" y="420"/> + </children> + <children xmi:type="notation:Node" xmi:id="_vaiTMKYzEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_vajhUKYzEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_vakIYKYzEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_vakIYaYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_vakIYqYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_vakIY6YzEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_vakvcKYzEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_vakvcaYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_vakvcqYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_vakvc6YzEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_vaiTMaYzEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//Assignee"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_vaiTMqYzEeGAP_kHrioTcA" x="294" y="279" width="124"/> + </children> + <children xmi:type="notation:Node" xmi:id="_x4_SoKYzEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_x5AgwKYzEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_x5BH0KYzEeGAP_kHrioTcA" type="5001"> + <children xmi:type="notation:Node" xmi:id="_JG0xkKY8EeGAP_kHrioTcA" type="2001"> + <element xmi:type="ecore:EAttribute" href="security.ecore#//Role/id"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_JG0xkaY8EeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_nrLEsKY8EeGAP_kHrioTcA" type="2001"> + <element xmi:type="ecore:EAttribute" href="security.ecore#//Role/type"/> + <layoutConstraint xmi:type="notation:Location" xmi:id="_nrLEsaY8EeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:DrawerStyle" xmi:id="_x5BH0aYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_x5BH0qYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_x5BH06YzEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_x5Bu4KYzEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_x5Bu4aYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_x5Bu4qYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_x5Bu46YzEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_x4_SoaYzEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//Role"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_x4_SoqYzEeGAP_kHrioTcA" x="45" y="271"/> + </children> + <children xmi:type="notation:Node" xmi:id="_2WagMKYzEeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_2WbuUKYzEeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_2WcVYKYzEeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_2WcVYaYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2WcVYqYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2WcVY6YzEeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_2Wc8cKYzEeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_2Wc8caYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_2Wc8cqYzEeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_2Wc8c6YzEeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_2WagMaYzEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//Directory"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_2WagMqYzEeGAP_kHrioTcA" x="464" y="279" width="119"/> + </children> + <children xmi:type="notation:Node" xmi:id="_btGCwKY0EeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_btHQ4KY0EeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_btHQ4aY0EeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_btHQ4qY0EeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_btH38KY0EeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_btH38aY0EeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_btIfAKY0EeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_btIfAaY0EeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_btIfAqY0EeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_btIfA6Y0EeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_btGCwaY0EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//SecurityItem"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_btGCwqY0EeGAP_kHrioTcA" x="292" y="151" width="128"/> + </children> + <children xmi:type="notation:Node" xmi:id="_L9EJcKY9EeGAP_kHrioTcA" type="1001"> + <children xmi:type="notation:Node" xmi:id="_L9EwgKY9EeGAP_kHrioTcA" type="4001"/> + <children xmi:type="notation:Node" xmi:id="_L9FXkKY9EeGAP_kHrioTcA" type="5001"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_L9FXkaY9EeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_L9FXkqY9EeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_L9FXk6Y9EeGAP_kHrioTcA"/> + </children> + <children xmi:type="notation:Node" xmi:id="_L9F-oKY9EeGAP_kHrioTcA" type="5002"> + <styles xmi:type="notation:DrawerStyle" xmi:id="_L9F-oaY9EeGAP_kHrioTcA"/> + <styles xmi:type="notation:SortingStyle" xmi:id="_L9F-oqY9EeGAP_kHrioTcA"/> + <styles xmi:type="notation:FilteringStyle" xmi:id="_L9F-o6Y9EeGAP_kHrioTcA"/> + </children> + <styles xmi:type="notation:ShapeStyle" xmi:id="_L9EJcaY9EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10" fillColor="13761016" lineColor="8421504"/> + <element xmi:type="ecore:EClass" href="security.ecore#//UserPassword"/> + <layoutConstraint xmi:type="notation:Bounds" xmi:id="_L9EJcqY9EeGAP_kHrioTcA" x="203" y="545" width="162"/> + </children> + <styles xmi:type="notation:DiagramStyle" xmi:id="_Lqg3UKYxEeGAP_kHrioTcA"/> + <element xmi:type="ecore:EPackage" href="security.ecore#/"/> + <edges xmi:type="notation:Edge" xmi:id="_ix63wKYxEeGAP_kHrioTcA" type="3003" source="_glO9wKYxEeGAP_kHrioTcA" target="_RJPJ0KYxEeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_ix63waYxEeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_ix63wqYxEeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_ix63w6YxEeGAP_kHrioTcA" points="[0, -24, -98, 71]$[0, -49, -98, 46]$[103, -49, 5, 46]$[103, -84, 5, 11]"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_olgfoKY0EeGAP_kHrioTcA" id="(0.4696969696969697,0.8356164383561644)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_ux6-kKY0EeGAP_kHrioTcA" type="3003" source="_kzdRsKYxEeGAP_kHrioTcA" target="_vaiTMKYzEeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_ux6-kaY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_ux6-kqY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_ux6-k6Y0EeGAP_kHrioTcA" points="[-1, -50, -73, 88]$[-1, -75, -73, 63]$[86, -75, 14, 63]$[86, -113, 14, 25]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_vUUhAKY0EeGAP_kHrioTcA" type="3003" source="_0ZWzEKYyEeGAP_kHrioTcA" target="_vaiTMKYzEeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_vUUhAaY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_vUVIEKY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_vUVIEaY0EeGAP_kHrioTcA" points="[-1, -20, 145, 117]$[-1, -74, 145, 63]$[-132, -74, 14, 63]$[-132, -112, 14, 25]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_wQRL4KY0EeGAP_kHrioTcA" type="3003" source="_x4_SoKYzEeGAP_kHrioTcA" target="_btGCwKY0EeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_wQRL4aY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_wQRL4qY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_wQRL46Y0EeGAP_kHrioTcA" points="[10, -33, -247, 100]$[10, -71, -247, 62]$[256, -71, -1, 62]$[256, -112, -1, 21]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_wrH74KY0EeGAP_kHrioTcA" type="3003" source="_vaiTMKYzEeGAP_kHrioTcA" target="_btGCwKY0EeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_wrH74aY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_wrH74qY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_wrH746Y0EeGAP_kHrioTcA" points="[-1, -24, -1, 108]$[-1, -111, -1, 21]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_5rz5QKY0EeGAP_kHrioTcA" type="3003" source="_2WagMKYzEeGAP_kHrioTcA" target="_btGCwKY0EeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_5rz5QaY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_5rz5QqY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_5rz5Q6Y0EeGAP_kHrioTcA" points="[4, -20, 171, 90]$[4, -55, 171, 55]$[-168, -55, -1, 55]$[-168, -89, -1, 21]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_6OjZ8KY0EeGAP_kHrioTcA" type="3003" source="_btGCwKY0EeGAP_kHrioTcA" target="_RJPJ0KYxEeGAP_kHrioTcA"> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_6OjZ8aY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_6OjZ8qY0EeGAP_kHrioTcA" fontName="Segoe UI"/> + <element xsi:nil="true"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_6OjZ86Y0EeGAP_kHrioTcA" points="[2, -20, 35, 96]$[2, -45, 35, 71]$[-113, -45, -80, 71]$[-113, -80, -80, 36]"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_6OnrYKY0EeGAP_kHrioTcA" id="(0.9040404040404041,0.4246575342465753)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="__CXuQKY0EeGAP_kHrioTcA" type="3002" source="_glO9wKYxEeGAP_kHrioTcA" target="_btGCwKY0EeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="__CY8YKY0EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="__CY8YaY0EeGAP_kHrioTcA" x="-15" y="-12"/> + </children> + <children xmi:type="notation:Node" xmi:id="__CY8YqY0EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="__CY8Y6Y0EeGAP_kHrioTcA" x="-6" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="__CXuQaY0EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="__CXuQqY0EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Realm/items"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="__CXuQ6Y0EeGAP_kHrioTcA" points="[56, 0, -166, 0]$[159, 0, -63, 0]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_DAH9QKY1EeGAP_kHrioTcA" type="3002" source="_2WagMKYzEeGAP_kHrioTcA" target="_btGCwKY0EeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_DAJLYKY1EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_DAJLYaY1EeGAP_kHrioTcA" x="25" y="-12"/> + </children> + <children xmi:type="notation:Node" xmi:id="_DAJLYqY1EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_DAJLY6Y1EeGAP_kHrioTcA" x="33" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_DAH9QaY1EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_DAH9QqY1EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Directory/items"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_DAH9Q6Y1EeGAP_kHrioTcA" points="[59, 0, 226, 132]$[88, 0, 255, 132]$[88, -132, 255, 0]$[-104, -132, 63, 0]"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_JwmLgKY1EeGAP_kHrioTcA" type="3002" source="_x4_SoKYzEeGAP_kHrioTcA" target="_vaiTMKYzEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_JwpO0KY1EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_JwpO0aY1EeGAP_kHrioTcA" x="-17" y="-12"/> + </children> + <children xmi:type="notation:Node" xmi:id="_Jwp14KY1EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_Jwp14aY1EeGAP_kHrioTcA" x="-1" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_JwmLgaY1EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_JwmLgqY1EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Role/assignees"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_JwmLg6Y1EeGAP_kHrioTcA" points="[53, -1, -204, 0]$[196, -1, -61, 0]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_M2vdEKY1EeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_M2vdEaY1EeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_Ll0nwKY1EeGAP_kHrioTcA" type="3002" source="_vaiTMKYzEeGAP_kHrioTcA" target="_x4_SoKYzEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_Ll114KY1EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_Ll114aY1EeGAP_kHrioTcA" x="-2" y="-12"/> + </children> + <children xmi:type="notation:Node" xmi:id="_Ll114qY1EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_Ll1146Y1EeGAP_kHrioTcA" x="3" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_Ll0nwaY1EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_Ll0nwqY1EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Assignee/roles"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_Ll0nw6Y1EeGAP_kHrioTcA" points="[-61, 0, 196, -1]$[-204, 0, 53, -1]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="__CxjoKZEEeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="__CxjoaZEEeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_Vog_QKY2EeGAP_kHrioTcA" type="3002" source="_kzdRsKYxEeGAP_kHrioTcA" target="_0ZWzEKYyEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_VoiNYKY2EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_VoiNYaY2EeGAP_kHrioTcA" x="-10" y="-10"/> + </children> + <children xmi:type="notation:Node" xmi:id="_Voi0cKY2EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_Voi0caY2EeGAP_kHrioTcA" x="3" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_Vog_QaY2EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_VohmUKY2EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//User/groups"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_VohmUaY2EeGAP_kHrioTcA" points="[69, -1, -149, 0]$[168, -1, -50, 0]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_iv_HoKY9EeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_iv_usKY9EeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_XSueUKY2EeGAP_kHrioTcA" type="3002" source="_0ZWzEKYyEeGAP_kHrioTcA" target="_kzdRsKYxEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_XSvFYKY2EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_XSvFYaY2EeGAP_kHrioTcA" x="-2" y="-12"/> + </children> + <children xmi:type="notation:Node" xmi:id="_XSvscKY2EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_XSvscaY2EeGAP_kHrioTcA" x="4" y="12"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_XSueUaY2EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_XSueUqY2EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Group/users"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_XSueU6Y2EeGAP_kHrioTcA" points="[-50, 0, 168, -1]$[-149, 0, 69, -1]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_Ynl_gKY2EeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_Ynl_gaY2EeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_b7R5oKY9EeGAP_kHrioTcA" type="3002" source="_kzdRsKYxEeGAP_kHrioTcA" target="_L9EJcKY9EeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_b7R5pKY9EeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_b7R5paY9EeGAP_kHrioTcA" x="-9" y="-31"/> + </children> + <children xmi:type="notation:Node" xmi:id="_b7SgsKY9EeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_b7SgsaY9EeGAP_kHrioTcA" x="-9" y="16"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_b7R5oaY9EeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_b7R5oqY9EeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//User/password"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_b7R5o6Y9EeGAP_kHrioTcA" points="[51, 52, -1, -78]$[51, 106, -1, -24]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_b7UV4KY9EeGAP_kHrioTcA" id="(0.12857142857142856,0.4803921568627451)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_v-aXIKZFEeGAP_kHrioTcA" type="3002" source="_0ZWzEKYyEeGAP_kHrioTcA" target="_0ZWzEKYyEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_v-blQKZFEeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_v-blQaZFEeGAP_kHrioTcA" x="31" y="52"/> + </children> + <children xmi:type="notation:Node" xmi:id="_v-blQqZFEeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_v-blQ6ZFEeGAP_kHrioTcA" x="31" y="-11"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_v-aXIaZFEeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_v-aXIqZFEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Group/inheritedGroups"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_v-aXI6ZFEeGAP_kHrioTcA" points="[50, 1, 50, 1]$[114, 1, 114, 1]$[114, 83, 114, 83]$[-1, 83, -1, 83]$[-1, 21, -1, 21]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_4r0zMKZFEeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_4r0zMaZFEeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> + <edges xmi:type="notation:Edge" xmi:id="_z6Tk8KZFEeGAP_kHrioTcA" type="3002" source="_0ZWzEKYyEeGAP_kHrioTcA" target="_0ZWzEKYyEeGAP_kHrioTcA"> + <children xmi:type="notation:Node" xmi:id="_z6UMA6ZFEeGAP_kHrioTcA" type="4011"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_z6UMBKZFEeGAP_kHrioTcA" x="-4" y="13"/> + </children> + <children xmi:type="notation:Node" xmi:id="_z6UMBaZFEeGAP_kHrioTcA" type="4012"> + <layoutConstraint xmi:type="notation:Location" xmi:id="_z6UMBqZFEeGAP_kHrioTcA" x="35" y="-11"/> + </children> + <styles xmi:type="notation:ConnectorStyle" xmi:id="_z6UMAKZFEeGAP_kHrioTcA" routing="Rectilinear" lineColor="4210752"/> + <styles xmi:type="notation:FontStyle" xmi:id="_z6UMAaZFEeGAP_kHrioTcA" fontColor="4210752" fontName="Segoe UI" fontHeight="10"/> + <element xmi:type="ecore:EReference" href="security.ecore#//Group/inheritingGroups"/> + <bendpoints xmi:type="notation:RelativeBendpoints" xmi:id="_z6UMAqZFEeGAP_kHrioTcA" points="[-1, 21, -1, 21]$[-1, 83, -1, 83]$[114, 83, 114, 83]$[114, 1, 114, 1]$[50, 1, 50, 1]"/> + <sourceAnchor xmi:type="notation:IdentityAnchor" xmi:id="_1vZeUKZFEeGAP_kHrioTcA" id="(0.5,0.5)"/> + <targetAnchor xmi:type="notation:IdentityAnchor" xmi:id="_1vZeUaZFEeGAP_kHrioTcA" id="(0.5,0.5)"/> + </edges> +</notation:Diagram> diff --git a/plugins/org.eclipse.emf.cdo.security/model/security.genmodel b/plugins/org.eclipse.emf.cdo.security/model/security.genmodel new file mode 100644 index 0000000000..70b371c761 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/model/security.genmodel @@ -0,0 +1,53 @@ +<?xml version="1.0" encoding="UTF-8"?> +<genmodel:GenModel xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" + xmlns:genmodel="http://www.eclipse.org/emf/2002/GenModel" modelDirectory="/org.eclipse.emf.cdo.security/src" creationIcons="false" + modelPluginID="org.eclipse.emf.cdo.security" modelName="Security" nonNLSMarkers="true" + rootExtendsInterface="org.eclipse.emf.cdo.CDOObject" rootExtendsClass="org.eclipse.emf.internal.cdo.CDOObjectImpl" + reflectiveDelegation="true" codeFormatting="true" testsDirectory="" importerID="org.eclipse.emf.importer.cdo" + featureDelegation="Reflective" complianceLevel="5.0" copyrightFields="false" optimizedHasChildren="true" + tableProviders="true" colorProviders="true" fontProviders="true" runtimeVersion="2.6" + usedGenPackages="platform:/plugin/org.eclipse.emf.ecore/model/Ecore.genmodel#//ecore ../../org.eclipse.emf.cdo/model/etypes.genmodel#//etypes"> + <foreignModel>security.ecore</foreignModel> + <modelPluginVariables>CDO=org.eclipse.emf.cdo</modelPluginVariables> + <genPackages prefix="Security" basePackage="org.eclipse.emf.cdo" disposableProviderFactory="true" + multipleEditorPages="false" extensibleProviderFactory="true" childCreationExtenders="true" + ecorePackage="security.ecore#/"> + <genClasses image="false" ecoreClass="security.ecore#//SecurityElement"> + <genOperations ecoreOperation="security.ecore#//SecurityElement/getRealm"/> + </genClasses> + <genClasses image="false" ecoreClass="security.ecore#//SecurityItem"/> + <genClasses ecoreClass="security.ecore#//Realm"> + <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference security.ecore#//Realm/items"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//Realm/name"/> + </genClasses> + <genClasses ecoreClass="security.ecore#//Directory"> + <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference security.ecore#//Directory/items"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//Directory/name"/> + </genClasses> + <genClasses ecoreClass="security.ecore#//Role"> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//Role/assignees"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//Role/id"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//Role/type"/> + </genClasses> + <genClasses image="false" ecoreClass="security.ecore#//Assignee"> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//Assignee/roles"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//Assignee/id"/> + </genClasses> + <genClasses ecoreClass="security.ecore#//Group"> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//Group/users"/> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//Group/inheritedGroups"/> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//Group/inheritingGroups"/> + </genClasses> + <genClasses ecoreClass="security.ecore#//User"> + <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference security.ecore#//User/groups"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//User/firstName"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//User/lastName"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//User/email"/> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//User/locked"/> + <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference security.ecore#//User/password"/> + </genClasses> + <genClasses ecoreClass="security.ecore#//UserPassword"> + <genFeatures createChild="false" ecoreFeature="ecore:EAttribute security.ecore#//UserPassword/encrypted"/> + </genClasses> + </genPackages> +</genmodel:GenModel> diff --git a/plugins/org.eclipse.emf.cdo.security/plugin.properties b/plugins/org.eclipse.emf.cdo.security/plugin.properties new file mode 100644 index 0000000000..b9a01a047e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/plugin.properties @@ -0,0 +1,11 @@ +# Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: +# Eike Stepper - initial API and implementation + +pluginName = CDO Model Repository Security Model +providerName = Eclipse Modeling Project diff --git a/plugins/org.eclipse.emf.cdo.security/plugin.xml b/plugins/org.eclipse.emf.cdo.security/plugin.xml new file mode 100644 index 0000000000..21903db04b --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/plugin.xml @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?eclipse version="3.4"?> +<!-- + Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + Eike Stepper - initial API and implementation +--> + +<plugin> + + <extension point="org.eclipse.emf.ecore.generated_package"> + <package + uri="http://www.eclipse.org/emf/CDO/security/4.1.0" + class="org.eclipse.emf.cdo.security.SecurityPackage" + genModel="model/security.genmodel"/> + </extension> + +</plugin> diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Assignee.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Assignee.java new file mode 100644 index 0000000000..f9b94d6f8b --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Assignee.java @@ -0,0 +1,78 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Assignee</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.Assignee#getRoles <em>Roles</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Assignee#getId <em>Id</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getAssignee() + * @model abstract="true" + * @generated + */ +public interface Assignee extends SecurityItem +{ + /** + * Returns the value of the '<em><b>Roles</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.Role}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.Role#getAssignees <em>Assignees</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Roles</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Roles</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getAssignee_Roles() + * @see org.eclipse.emf.cdo.security.Role#getAssignees + * @model opposite="assignees" + * @generated + */ + EList<Role> getRoles(); + + /** + * Returns the value of the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Id</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Id</em>' attribute. + * @see #setId(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getAssignee_Id() + * @model + * @generated + */ + String getId(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.Assignee#getId <em>Id</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Id</em>' attribute. + * @see #getId() + * @generated + */ + void setId(String value); + +} // Assignee diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Directory.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Directory.java new file mode 100644 index 0000000000..cad5a7dbf5 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Directory.java @@ -0,0 +1,76 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Container</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.Directory#getItems <em>Items</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Directory#getName <em>Name</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getDirectory() + * @model + * @generated + */ +public interface Directory extends SecurityItem +{ + /** + * Returns the value of the '<em><b>Items</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.SecurityItem}. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Items</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Items</em>' containment reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getDirectory_Items() + * @model containment="true" + * @generated + */ + EList<SecurityItem> getItems(); + + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getDirectory_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.Directory#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + +} // Container diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Group.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Group.java new file mode 100644 index 0000000000..32f7e31e93 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Group.java @@ -0,0 +1,89 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Group</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.Group#getInheritedGroups <em>Inherited Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Group#getInheritingGroups <em>Inheriting Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Group#getUsers <em>Users</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getGroup() + * @model + * @generated + */ +public interface Group extends Assignee +{ + /** + * Returns the value of the '<em><b>Users</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.User}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.User#getGroups <em>Groups</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Users</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Users</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getGroup_Users() + * @see org.eclipse.emf.cdo.security.User#getGroups + * @model opposite="groups" + * @generated + */ + EList<User> getUsers(); + + /** + * Returns the value of the '<em><b>Inherited Groups</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.Group}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.Group#getInheritingGroups <em>Inheriting Groups</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Inherited Groups</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Inherited Groups</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getGroup_InheritedGroups() + * @see org.eclipse.emf.cdo.security.Group#getInheritingGroups + * @model opposite="inheritingGroups" + * @generated + */ + EList<Group> getInheritedGroups(); + + /** + * Returns the value of the '<em><b>Inheriting Groups</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.Group}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.Group#getInheritedGroups <em>Inherited Groups</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Inheriting Groups</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Inheriting Groups</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getGroup_InheritingGroups() + * @see org.eclipse.emf.cdo.security.Group#getInheritedGroups + * @model opposite="inheritedGroups" + * @generated + */ + EList<Group> getInheritingGroups(); + +} // Group diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Realm.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Realm.java new file mode 100644 index 0000000000..312e694bd2 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Realm.java @@ -0,0 +1,76 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Realm</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.Realm#getItems <em>Items</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Realm#getName <em>Name</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRealm() + * @model + * @generated + */ +public interface Realm extends SecurityElement +{ + /** + * Returns the value of the '<em><b>Items</b></em>' containment reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.SecurityItem}. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Items</em>' containment reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Items</em>' containment reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRealm_Items() + * @model containment="true" + * @generated + */ + EList<SecurityItem> getItems(); + + /** + * Returns the value of the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Name</em>' attribute. + * @see #setName(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRealm_Name() + * @model + * @generated + */ + String getName(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.Realm#getName <em>Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Name</em>' attribute. + * @see #getName() + * @generated + */ + void setName(String value); + +} // SecurityRealm diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Role.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Role.java new file mode 100644 index 0000000000..7fdbf89aab --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/Role.java @@ -0,0 +1,105 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Role</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.Role#getAssignees <em>Assignees</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Role#getId <em>Id</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.Role#getType <em>Type</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRole() + * @model + * @generated + */ +public interface Role extends SecurityItem +{ + /** + * Returns the value of the '<em><b>Assignees</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.Assignee}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.Assignee#getRoles <em>Roles</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Assignees</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Assignees</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRole_Assignees() + * @see org.eclipse.emf.cdo.security.Assignee#getRoles + * @model opposite="roles" + * @generated + */ + EList<Assignee> getAssignees(); + + /** + * Returns the value of the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Id</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Id</em>' attribute. + * @see #setId(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRole_Id() + * @model + * @generated + */ + String getId(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.Role#getId <em>Id</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Id</em>' attribute. + * @see #getId() + * @generated + */ + void setId(String value); + + /** + * Returns the value of the '<em><b>Type</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Type</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Type</em>' attribute. + * @see #setType(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getRole_Type() + * @model + * @generated + */ + String getType(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.Role#getType <em>Type</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Type</em>' attribute. + * @see #getType() + * @generated + */ + void setType(String value); + +} // Role diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityElement.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityElement.java new file mode 100644 index 0000000000..770a05179d --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityElement.java @@ -0,0 +1,35 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.cdo.etypes.ModelElement; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Element</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getSecurityElement() + * @model abstract="true" + * @generated + */ +public interface SecurityElement extends ModelElement +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @model kind="operation" required="true" + * @generated + */ + Realm getRealm(); + +} // SecurityElement diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityFactory.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityFactory.java new file mode 100644 index 0000000000..78297dda13 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityFactory.java @@ -0,0 +1,96 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.ecore.EFactory; + +/** + * <!-- begin-user-doc --> + * The <b>Factory</b> for the model. + * It provides a create method for each non-abstract class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.SecurityPackage + * @generated + */ +public interface SecurityFactory extends EFactory +{ + /** + * The singleton instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SecurityFactory eINSTANCE = org.eclipse.emf.cdo.security.impl.SecurityFactoryImpl.init(); + + /** + * Returns a new object of class '<em>Realm</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Realm</em>'. + * @generated + */ + Realm createRealm(); + + /** + * Returns a new object of class '<em>Directory</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Directory</em>'. + * @generated + */ + Directory createDirectory(); + + /** + * Returns a new object of class '<em>Role</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Role</em>'. + * @generated + */ + Role createRole(); + + /** + * Returns a new object of class '<em>Group</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>Group</em>'. + * @generated + */ + Group createGroup(); + + /** + * Returns a new object of class '<em>User</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>User</em>'. + * @generated + */ + User createUser(); + + /** + * Returns a new object of class '<em>User Password</em>'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return a new object of class '<em>User Password</em>'. + * @generated + */ + UserPassword createUserPassword(); + + /** + * Returns the package supported by this factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the package supported by this factory. + * @generated + */ + SecurityPackage getSecurityPackage(); + +} // SecurityFactory diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityItem.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityItem.java new file mode 100644 index 0000000000..9be64271d9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityItem.java @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>Item</b></em>'. + * <!-- end-user-doc --> + * + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getSecurityItem() + * @model abstract="true" + * @generated + */ +public interface SecurityItem extends SecurityElement +{ +} // SecurityItem diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityPackage.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityPackage.java new file mode 100644 index 0000000000..b4390870fb --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/SecurityPackage.java @@ -0,0 +1,1085 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.cdo.etypes.EtypesPackage; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; + +/** + * <!-- begin-user-doc --> + * The <b>Package</b> for the model. + * It contains accessors for the meta objects to represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.SecurityFactory + * @model kind="package" + * @generated + */ +public interface SecurityPackage extends EPackage +{ + /** + * The package name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNAME = "security"; //$NON-NLS-1$ + + /** + * The package namespace URI. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_URI = "http://www.eclipse.org/emf/CDO/security/4.1.0"; //$NON-NLS-1$ + + /** + * The package namespace name. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + String eNS_PREFIX = "security"; //$NON-NLS-1$ + + /** + * The singleton instance of the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + SecurityPackage eINSTANCE = org.eclipse.emf.cdo.security.impl.SecurityPackageImpl.init(); + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.SecurityElementImpl <em>Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.SecurityElementImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getSecurityElement() + * @generated + */ + int SECURITY_ELEMENT = 0; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SECURITY_ELEMENT__ANNOTATIONS = EtypesPackage.MODEL_ELEMENT__ANNOTATIONS; + + /** + * The number of structural features of the '<em>Element</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SECURITY_ELEMENT_FEATURE_COUNT = EtypesPackage.MODEL_ELEMENT_FEATURE_COUNT + 0; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.RealmImpl <em>Realm</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.RealmImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getRealm() + * @generated + */ + int REALM = 2; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.DirectoryImpl <em>Directory</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.DirectoryImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getDirectory() + * @generated + */ + int DIRECTORY = 3; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.SecurityItemImpl <em>Item</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.SecurityItemImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getSecurityItem() + * @generated + */ + int SECURITY_ITEM = 1; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SECURITY_ITEM__ANNOTATIONS = SECURITY_ELEMENT__ANNOTATIONS; + + /** + * The number of structural features of the '<em>Item</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int SECURITY_ITEM_FEATURE_COUNT = SECURITY_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int REALM__ANNOTATIONS = SECURITY_ELEMENT__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Items</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int REALM__ITEMS = SECURITY_ELEMENT_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int REALM__NAME = SECURITY_ELEMENT_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Realm</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int REALM_FEATURE_COUNT = SECURITY_ELEMENT_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int DIRECTORY__ANNOTATIONS = SECURITY_ITEM__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Items</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int DIRECTORY__ITEMS = SECURITY_ITEM_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int DIRECTORY__NAME = SECURITY_ITEM_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Directory</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int DIRECTORY_FEATURE_COUNT = SECURITY_ITEM_FEATURE_COUNT + 2; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.RoleImpl <em>Role</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.RoleImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getRole() + * @generated + */ + int ROLE = 4; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ROLE__ANNOTATIONS = SECURITY_ITEM__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Assignees</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ROLE__ASSIGNEES = SECURITY_ITEM_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ROLE__ID = SECURITY_ITEM_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Type</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ROLE__TYPE = SECURITY_ITEM_FEATURE_COUNT + 2; + + /** + * The number of structural features of the '<em>Role</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ROLE_FEATURE_COUNT = SECURITY_ITEM_FEATURE_COUNT + 3; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.AssigneeImpl <em>Assignee</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.AssigneeImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getAssignee() + * @generated + */ + int ASSIGNEE = 5; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSIGNEE__ANNOTATIONS = SECURITY_ITEM__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Roles</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSIGNEE__ROLES = SECURITY_ITEM_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSIGNEE__ID = SECURITY_ITEM_FEATURE_COUNT + 1; + + /** + * The number of structural features of the '<em>Assignee</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int ASSIGNEE_FEATURE_COUNT = SECURITY_ITEM_FEATURE_COUNT + 2; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.GroupImpl <em>Group</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.GroupImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getGroup() + * @generated + */ + int GROUP = 6; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__ANNOTATIONS = ASSIGNEE__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Roles</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__ROLES = ASSIGNEE__ROLES; + + /** + * The feature id for the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__ID = ASSIGNEE__ID; + + /** + * The feature id for the '<em><b>Inherited Groups</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__INHERITED_GROUPS = ASSIGNEE_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>Inheriting Groups</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__INHERITING_GROUPS = ASSIGNEE_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Users</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP__USERS = ASSIGNEE_FEATURE_COUNT + 2; + + /** + * The number of structural features of the '<em>Group</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int GROUP_FEATURE_COUNT = ASSIGNEE_FEATURE_COUNT + 3; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.UserImpl <em>User</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.UserImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getUser() + * @generated + */ + int USER = 7; + + /** + * The feature id for the '<em><b>Annotations</b></em>' containment reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__ANNOTATIONS = ASSIGNEE__ANNOTATIONS; + + /** + * The feature id for the '<em><b>Roles</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__ROLES = ASSIGNEE__ROLES; + + /** + * The feature id for the '<em><b>Id</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__ID = ASSIGNEE__ID; + + /** + * The feature id for the '<em><b>Groups</b></em>' reference list. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__GROUPS = ASSIGNEE_FEATURE_COUNT + 0; + + /** + * The feature id for the '<em><b>First Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__FIRST_NAME = ASSIGNEE_FEATURE_COUNT + 1; + + /** + * The feature id for the '<em><b>Last Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__LAST_NAME = ASSIGNEE_FEATURE_COUNT + 2; + + /** + * The feature id for the '<em><b>Email</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__EMAIL = ASSIGNEE_FEATURE_COUNT + 3; + + /** + * The feature id for the '<em><b>Locked</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__LOCKED = ASSIGNEE_FEATURE_COUNT + 4; + + /** + * The feature id for the '<em><b>Password</b></em>' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER__PASSWORD = ASSIGNEE_FEATURE_COUNT + 5; + + /** + * The number of structural features of the '<em>User</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER_FEATURE_COUNT = ASSIGNEE_FEATURE_COUNT + 6; + + /** + * The meta object id for the '{@link org.eclipse.emf.cdo.security.impl.UserPasswordImpl <em>User Password</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.UserPasswordImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getUserPassword() + * @generated + */ + int USER_PASSWORD = 8; + + /** + * The feature id for the '<em><b>Encrypted</b></em>' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER_PASSWORD__ENCRYPTED = 0; + + /** + * The number of structural features of the '<em>User Password</em>' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + * @ordered + */ + int USER_PASSWORD_FEATURE_COUNT = 1; + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.SecurityElement <em>Element</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Element</em>'. + * @see org.eclipse.emf.cdo.security.SecurityElement + * @generated + */ + EClass getSecurityElement(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.Realm <em>Realm</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Realm</em>'. + * @see org.eclipse.emf.cdo.security.Realm + * @generated + */ + EClass getRealm(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.emf.cdo.security.Realm#getItems <em>Items</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Items</em>'. + * @see org.eclipse.emf.cdo.security.Realm#getItems() + * @see #getRealm() + * @generated + */ + EReference getRealm_Items(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.Realm#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.emf.cdo.security.Realm#getName() + * @see #getRealm() + * @generated + */ + EAttribute getRealm_Name(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.Directory <em>Directory</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Directory</em>'. + * @see org.eclipse.emf.cdo.security.Directory + * @generated + */ + EClass getDirectory(); + + /** + * Returns the meta object for the containment reference list '{@link org.eclipse.emf.cdo.security.Directory#getItems <em>Items</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference list '<em>Items</em>'. + * @see org.eclipse.emf.cdo.security.Directory#getItems() + * @see #getDirectory() + * @generated + */ + EReference getDirectory_Items(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.Directory#getName <em>Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Name</em>'. + * @see org.eclipse.emf.cdo.security.Directory#getName() + * @see #getDirectory() + * @generated + */ + EAttribute getDirectory_Name(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.SecurityItem <em>Item</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Item</em>'. + * @see org.eclipse.emf.cdo.security.SecurityItem + * @generated + */ + EClass getSecurityItem(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.Role <em>Role</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Role</em>'. + * @see org.eclipse.emf.cdo.security.Role + * @generated + */ + EClass getRole(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.Role#getAssignees <em>Assignees</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Assignees</em>'. + * @see org.eclipse.emf.cdo.security.Role#getAssignees() + * @see #getRole() + * @generated + */ + EReference getRole_Assignees(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.Role#getId <em>Id</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Id</em>'. + * @see org.eclipse.emf.cdo.security.Role#getId() + * @see #getRole() + * @generated + */ + EAttribute getRole_Id(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.Role#getType <em>Type</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Type</em>'. + * @see org.eclipse.emf.cdo.security.Role#getType() + * @see #getRole() + * @generated + */ + EAttribute getRole_Type(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.Assignee <em>Assignee</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Assignee</em>'. + * @see org.eclipse.emf.cdo.security.Assignee + * @generated + */ + EClass getAssignee(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.Assignee#getRoles <em>Roles</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Roles</em>'. + * @see org.eclipse.emf.cdo.security.Assignee#getRoles() + * @see #getAssignee() + * @generated + */ + EReference getAssignee_Roles(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.Assignee#getId <em>Id</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Id</em>'. + * @see org.eclipse.emf.cdo.security.Assignee#getId() + * @see #getAssignee() + * @generated + */ + EAttribute getAssignee_Id(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.Group <em>Group</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>Group</em>'. + * @see org.eclipse.emf.cdo.security.Group + * @generated + */ + EClass getGroup(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.Group#getUsers <em>Users</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Users</em>'. + * @see org.eclipse.emf.cdo.security.Group#getUsers() + * @see #getGroup() + * @generated + */ + EReference getGroup_Users(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.Group#getInheritedGroups <em>Inherited Groups</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Inherited Groups</em>'. + * @see org.eclipse.emf.cdo.security.Group#getInheritedGroups() + * @see #getGroup() + * @generated + */ + EReference getGroup_InheritedGroups(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.Group#getInheritingGroups <em>Inheriting Groups</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Inheriting Groups</em>'. + * @see org.eclipse.emf.cdo.security.Group#getInheritingGroups() + * @see #getGroup() + * @generated + */ + EReference getGroup_InheritingGroups(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.User <em>User</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>User</em>'. + * @see org.eclipse.emf.cdo.security.User + * @generated + */ + EClass getUser(); + + /** + * Returns the meta object for the reference list '{@link org.eclipse.emf.cdo.security.User#getGroups <em>Groups</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the reference list '<em>Groups</em>'. + * @see org.eclipse.emf.cdo.security.User#getGroups() + * @see #getUser() + * @generated + */ + EReference getUser_Groups(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.User#getFirstName <em>First Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>First Name</em>'. + * @see org.eclipse.emf.cdo.security.User#getFirstName() + * @see #getUser() + * @generated + */ + EAttribute getUser_FirstName(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.User#getLastName <em>Last Name</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Last Name</em>'. + * @see org.eclipse.emf.cdo.security.User#getLastName() + * @see #getUser() + * @generated + */ + EAttribute getUser_LastName(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.User#getEmail <em>Email</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Email</em>'. + * @see org.eclipse.emf.cdo.security.User#getEmail() + * @see #getUser() + * @generated + */ + EAttribute getUser_Email(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.User#isLocked <em>Locked</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Locked</em>'. + * @see org.eclipse.emf.cdo.security.User#isLocked() + * @see #getUser() + * @generated + */ + EAttribute getUser_Locked(); + + /** + * Returns the meta object for the containment reference '{@link org.eclipse.emf.cdo.security.User#getPassword <em>Password</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the containment reference '<em>Password</em>'. + * @see org.eclipse.emf.cdo.security.User#getPassword() + * @see #getUser() + * @generated + */ + EReference getUser_Password(); + + /** + * Returns the meta object for class '{@link org.eclipse.emf.cdo.security.UserPassword <em>User Password</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for class '<em>User Password</em>'. + * @see org.eclipse.emf.cdo.security.UserPassword + * @generated + */ + EClass getUserPassword(); + + /** + * Returns the meta object for the attribute '{@link org.eclipse.emf.cdo.security.UserPassword#getEncrypted <em>Encrypted</em>}'. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the meta object for the attribute '<em>Encrypted</em>'. + * @see org.eclipse.emf.cdo.security.UserPassword#getEncrypted() + * @see #getUserPassword() + * @generated + */ + EAttribute getUserPassword_Encrypted(); + + /** + * Returns the factory that creates the instances of the model. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the factory that creates the instances of the model. + * @generated + */ + SecurityFactory getSecurityFactory(); + + /** + * <!-- begin-user-doc --> + * Defines literals for the meta objects that represent + * <ul> + * <li>each class,</li> + * <li>each feature of each class,</li> + * <li>each enum,</li> + * <li>and each data type</li> + * </ul> + * <!-- end-user-doc --> + * @generated + */ + interface Literals + { + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.SecurityElementImpl <em>Element</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.SecurityElementImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getSecurityElement() + * @generated + */ + EClass SECURITY_ELEMENT = eINSTANCE.getSecurityElement(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.RealmImpl <em>Realm</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.RealmImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getRealm() + * @generated + */ + EClass REALM = eINSTANCE.getRealm(); + + /** + * The meta object literal for the '<em><b>Items</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference REALM__ITEMS = eINSTANCE.getRealm_Items(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute REALM__NAME = eINSTANCE.getRealm_Name(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.DirectoryImpl <em>Directory</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.DirectoryImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getDirectory() + * @generated + */ + EClass DIRECTORY = eINSTANCE.getDirectory(); + + /** + * The meta object literal for the '<em><b>Items</b></em>' containment reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference DIRECTORY__ITEMS = eINSTANCE.getDirectory_Items(); + + /** + * The meta object literal for the '<em><b>Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute DIRECTORY__NAME = eINSTANCE.getDirectory_Name(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.SecurityItemImpl <em>Item</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.SecurityItemImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getSecurityItem() + * @generated + */ + EClass SECURITY_ITEM = eINSTANCE.getSecurityItem(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.RoleImpl <em>Role</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.RoleImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getRole() + * @generated + */ + EClass ROLE = eINSTANCE.getRole(); + + /** + * The meta object literal for the '<em><b>Assignees</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ROLE__ASSIGNEES = eINSTANCE.getRole_Assignees(); + + /** + * The meta object literal for the '<em><b>Id</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute ROLE__ID = eINSTANCE.getRole_Id(); + + /** + * The meta object literal for the '<em><b>Type</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute ROLE__TYPE = eINSTANCE.getRole_Type(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.AssigneeImpl <em>Assignee</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.AssigneeImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getAssignee() + * @generated + */ + EClass ASSIGNEE = eINSTANCE.getAssignee(); + + /** + * The meta object literal for the '<em><b>Roles</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference ASSIGNEE__ROLES = eINSTANCE.getAssignee_Roles(); + + /** + * The meta object literal for the '<em><b>Id</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute ASSIGNEE__ID = eINSTANCE.getAssignee_Id(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.GroupImpl <em>Group</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.GroupImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getGroup() + * @generated + */ + EClass GROUP = eINSTANCE.getGroup(); + + /** + * The meta object literal for the '<em><b>Users</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference GROUP__USERS = eINSTANCE.getGroup_Users(); + + /** + * The meta object literal for the '<em><b>Inherited Groups</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference GROUP__INHERITED_GROUPS = eINSTANCE.getGroup_InheritedGroups(); + + /** + * The meta object literal for the '<em><b>Inheriting Groups</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference GROUP__INHERITING_GROUPS = eINSTANCE.getGroup_InheritingGroups(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.UserImpl <em>User</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.UserImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getUser() + * @generated + */ + EClass USER = eINSTANCE.getUser(); + + /** + * The meta object literal for the '<em><b>Groups</b></em>' reference list feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference USER__GROUPS = eINSTANCE.getUser_Groups(); + + /** + * The meta object literal for the '<em><b>First Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute USER__FIRST_NAME = eINSTANCE.getUser_FirstName(); + + /** + * The meta object literal for the '<em><b>Last Name</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute USER__LAST_NAME = eINSTANCE.getUser_LastName(); + + /** + * The meta object literal for the '<em><b>Email</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute USER__EMAIL = eINSTANCE.getUser_Email(); + + /** + * The meta object literal for the '<em><b>Locked</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute USER__LOCKED = eINSTANCE.getUser_Locked(); + + /** + * The meta object literal for the '<em><b>Password</b></em>' containment reference feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EReference USER__PASSWORD = eINSTANCE.getUser_Password(); + + /** + * The meta object literal for the '{@link org.eclipse.emf.cdo.security.impl.UserPasswordImpl <em>User Password</em>}' class. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.impl.UserPasswordImpl + * @see org.eclipse.emf.cdo.security.impl.SecurityPackageImpl#getUserPassword() + * @generated + */ + EClass USER_PASSWORD = eINSTANCE.getUserPassword(); + + /** + * The meta object literal for the '<em><b>Encrypted</b></em>' attribute feature. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + EAttribute USER_PASSWORD__ENCRYPTED = eINSTANCE.getUserPassword_Encrypted(); + + } + +} // SecurityPackage diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/User.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/User.java new file mode 100644 index 0000000000..5090f476d6 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/User.java @@ -0,0 +1,186 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.common.util.EList; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>User</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.User#getGroups <em>Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.User#getFirstName <em>First Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.User#getLastName <em>Last Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.User#getEmail <em>Email</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.User#isLocked <em>Locked</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.User#getPassword <em>Password</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser() + * @model + * @generated + */ +public interface User extends Assignee +{ + /** + * Returns the value of the '<em><b>Groups</b></em>' reference list. + * The list contents are of type {@link org.eclipse.emf.cdo.security.Group}. + * It is bidirectional and its opposite is '{@link org.eclipse.emf.cdo.security.Group#getUsers <em>Users</em>}'. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Groups</em>' reference list isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Groups</em>' reference list. + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_Groups() + * @see org.eclipse.emf.cdo.security.Group#getUsers + * @model opposite="users" + * @generated + */ + EList<Group> getGroups(); + + /** + * Returns the value of the '<em><b>First Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>First Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>First Name</em>' attribute. + * @see #setFirstName(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_FirstName() + * @model + * @generated + */ + String getFirstName(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.User#getFirstName <em>First Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>First Name</em>' attribute. + * @see #getFirstName() + * @generated + */ + void setFirstName(String value); + + /** + * Returns the value of the '<em><b>Last Name</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Last Name</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Last Name</em>' attribute. + * @see #setLastName(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_LastName() + * @model + * @generated + */ + String getLastName(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.User#getLastName <em>Last Name</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Last Name</em>' attribute. + * @see #getLastName() + * @generated + */ + void setLastName(String value); + + /** + * Returns the value of the '<em><b>Email</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Email</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Email</em>' attribute. + * @see #setEmail(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_Email() + * @model + * @generated + */ + String getEmail(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.User#getEmail <em>Email</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Email</em>' attribute. + * @see #getEmail() + * @generated + */ + void setEmail(String value); + + /** + * Returns the value of the '<em><b>Locked</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Locked</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Locked</em>' attribute. + * @see #setLocked(boolean) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_Locked() + * @model + * @generated + */ + boolean isLocked(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.User#isLocked <em>Locked</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Locked</em>' attribute. + * @see #isLocked() + * @generated + */ + void setLocked(boolean value); + + /** + * Returns the value of the '<em><b>Password</b></em>' containment reference. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Password</em>' containment reference isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Password</em>' containment reference. + * @see #setPassword(UserPassword) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUser_Password() + * @model containment="true" + * @generated + */ + UserPassword getPassword(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.User#getPassword <em>Password</em>}' containment reference. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Password</em>' containment reference. + * @see #getPassword() + * @generated + */ + void setPassword(UserPassword value); + +} // User diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/UserPassword.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/UserPassword.java new file mode 100644 index 0000000000..6ee2cc958f --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/UserPassword.java @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security; + +import org.eclipse.emf.cdo.CDOObject; + +/** + * <!-- begin-user-doc --> + * A representation of the model object '<em><b>User Password</b></em>'. + * <!-- end-user-doc --> + * + * <p> + * The following features are supported: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.UserPassword#getEncrypted <em>Encrypted</em>}</li> + * </ul> + * </p> + * + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUserPassword() + * @model + * @extends CDOObject + * @generated + */ +public interface UserPassword extends CDOObject +{ + /** + * Returns the value of the '<em><b>Encrypted</b></em>' attribute. + * <!-- begin-user-doc --> + * <p> + * If the meaning of the '<em>Encrypted</em>' attribute isn't clear, + * there really should be more of a description here... + * </p> + * <!-- end-user-doc --> + * @return the value of the '<em>Encrypted</em>' attribute. + * @see #setEncrypted(String) + * @see org.eclipse.emf.cdo.security.SecurityPackage#getUserPassword_Encrypted() + * @model + * @generated + */ + String getEncrypted(); + + /** + * Sets the value of the '{@link org.eclipse.emf.cdo.security.UserPassword#getEncrypted <em>Encrypted</em>}' attribute. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param value the new value of the '<em>Encrypted</em>' attribute. + * @see #getEncrypted() + * @generated + */ + void setEncrypted(String value); + +} // UserPassword diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/AssigneeImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/AssigneeImpl.java new file mode 100644 index 0000000000..752bfe3895 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/AssigneeImpl.java @@ -0,0 +1,88 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Assignee</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.AssigneeImpl#getRoles <em>Roles</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.AssigneeImpl#getId <em>Id</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public abstract class AssigneeImpl extends SecurityItemImpl implements Assignee +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected AssigneeImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.ASSIGNEE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<Role> getRoles() + { + return (EList<Role>)eGet(SecurityPackage.Literals.ASSIGNEE__ROLES, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getId() + { + return (String)eGet(SecurityPackage.Literals.ASSIGNEE__ID, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setId(String newId) + { + eSet(SecurityPackage.Literals.ASSIGNEE__ID, newId); + } + +} // AssigneeImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/DirectoryImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/DirectoryImpl.java new file mode 100644 index 0000000000..0f3e9538cf --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/DirectoryImpl.java @@ -0,0 +1,88 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Container</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.DirectoryImpl#getItems <em>Items</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.DirectoryImpl#getName <em>Name</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class DirectoryImpl extends SecurityItemImpl implements Directory +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected DirectoryImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.DIRECTORY; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<SecurityItem> getItems() + { + return (EList<SecurityItem>)eGet(SecurityPackage.Literals.DIRECTORY__ITEMS, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() + { + return (String)eGet(SecurityPackage.Literals.DIRECTORY__NAME, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) + { + eSet(SecurityPackage.Literals.DIRECTORY__NAME, newName); + } + +} // ContainerImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/GroupImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/GroupImpl.java new file mode 100644 index 0000000000..ca4a5b30ca --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/GroupImpl.java @@ -0,0 +1,91 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Group</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.GroupImpl#getInheritedGroups <em>Inherited Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.GroupImpl#getInheritingGroups <em>Inheriting Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.GroupImpl#getUsers <em>Users</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class GroupImpl extends AssigneeImpl implements Group +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected GroupImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.GROUP; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<User> getUsers() + { + return (EList<User>)eGet(SecurityPackage.Literals.GROUP__USERS, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<Group> getInheritedGroups() + { + return (EList<Group>)eGet(SecurityPackage.Literals.GROUP__INHERITED_GROUPS, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<Group> getInheritingGroups() + { + return (EList<Group>)eGet(SecurityPackage.Literals.GROUP__INHERITING_GROUPS, true); + } + +} // GroupImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RealmImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RealmImpl.java new file mode 100644 index 0000000000..d9fff79b5e --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RealmImpl.java @@ -0,0 +1,94 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Realm</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.RealmImpl#getItems <em>Items</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.RealmImpl#getName <em>Name</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class RealmImpl extends SecurityElementImpl implements Realm +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected RealmImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.REALM; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<SecurityItem> getItems() + { + return (EList<SecurityItem>)eGet(SecurityPackage.Literals.REALM__ITEMS, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getName() + { + return (String)eGet(SecurityPackage.Literals.REALM__NAME, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setName(String newName) + { + eSet(SecurityPackage.Literals.REALM__NAME, newName); + } + + @Override + public Realm getRealm() + { + return this; + } + +} // SecurityRealmImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RoleImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RoleImpl.java new file mode 100644 index 0000000000..091bb3bac6 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/RoleImpl.java @@ -0,0 +1,109 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Role</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.RoleImpl#getAssignees <em>Assignees</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.RoleImpl#getId <em>Id</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.RoleImpl#getType <em>Type</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class RoleImpl extends SecurityItemImpl implements Role +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected RoleImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.ROLE; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<Assignee> getAssignees() + { + return (EList<Assignee>)eGet(SecurityPackage.Literals.ROLE__ASSIGNEES, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getId() + { + return (String)eGet(SecurityPackage.Literals.ROLE__ID, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setId(String newId) + { + eSet(SecurityPackage.Literals.ROLE__ID, newId); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getType() + { + return (String)eGet(SecurityPackage.Literals.ROLE__TYPE, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setType(String newType) + { + eSet(SecurityPackage.Literals.ROLE__TYPE, newType); + } + +} // RoleImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityElementImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityElementImpl.java new file mode 100644 index 0000000000..a9743eb100 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityElementImpl.java @@ -0,0 +1,69 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.etypes.impl.ModelElementImpl; +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.SecurityElement; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Element</b></em>'. + * <!-- end-user-doc --> + * <p> + * </p> + * + * @generated + */ +public abstract class SecurityElementImpl extends ModelElementImpl implements SecurityElement +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityElementImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.SECURITY_ELEMENT; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated NOT + */ + public Realm getRealm() + { + EObject container = eContainer(); + if (container instanceof SecurityElement) + { + return ((SecurityElement)container).getRealm(); + } + + return null; + } + +} // SecurityElementImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityFactoryImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityFactoryImpl.java new file mode 100644 index 0000000000..3b0f840b83 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityFactoryImpl.java @@ -0,0 +1,186 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.impl.EFactoryImpl; +import org.eclipse.emf.ecore.plugin.EcorePlugin; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Factory</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SecurityFactoryImpl extends EFactoryImpl implements SecurityFactory +{ + /** + * Creates the default factory implementation. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public static SecurityFactory init() + { + try + { + SecurityFactory theSecurityFactory = (SecurityFactory)EPackage.Registry.INSTANCE + .getEFactory("http://www.eclipse.org/emf/CDO/security/4.1.0"); //$NON-NLS-1$ + if (theSecurityFactory != null) + { + return theSecurityFactory; + } + } + catch (Exception exception) + { + EcorePlugin.INSTANCE.log(exception); + } + return new SecurityFactoryImpl(); + } + + /** + * Creates an instance of the factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityFactoryImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + public EObject create(EClass eClass) + { + switch (eClass.getClassifierID()) + { + case SecurityPackage.REALM: + return createRealm(); + case SecurityPackage.DIRECTORY: + return createDirectory(); + case SecurityPackage.ROLE: + return createRole(); + case SecurityPackage.GROUP: + return createGroup(); + case SecurityPackage.USER: + return createUser(); + case SecurityPackage.USER_PASSWORD: + return createUserPassword(); + default: + throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); //$NON-NLS-1$ //$NON-NLS-2$ + } + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Realm createRealm() + { + RealmImpl realm = new RealmImpl(); + return realm; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Directory createDirectory() + { + DirectoryImpl directory = new DirectoryImpl(); + return directory; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Role createRole() + { + RoleImpl role = new RoleImpl(); + return role; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public Group createGroup() + { + GroupImpl group = new GroupImpl(); + return group; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public User createUser() + { + UserImpl user = new UserImpl(); + return user; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public UserPassword createUserPassword() + { + UserPasswordImpl userPassword = new UserPasswordImpl(); + return userPassword; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityPackage getSecurityPackage() + { + return (SecurityPackage)getEPackage(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @deprecated + * @generated + */ + @Deprecated + public static SecurityPackage getPackage() + { + return SecurityPackage.eINSTANCE; + } + +} // SecurityFactoryImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityItemImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityItemImpl.java new file mode 100644 index 0000000000..4f4975bdf2 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityItemImpl.java @@ -0,0 +1,50 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; + +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>Item</b></em>'. + * <!-- end-user-doc --> + * <p> + * </p> + * + * @generated + */ +public abstract class SecurityItemImpl extends SecurityElementImpl implements SecurityItem +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecurityItemImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.SECURITY_ITEM; + } + +} // SecurityItemImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityPackageImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityPackageImpl.java new file mode 100644 index 0000000000..f6c2e83ec0 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/SecurityPackageImpl.java @@ -0,0 +1,682 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.etypes.EtypesPackage; +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityElement; +import org.eclipse.emf.cdo.security.SecurityFactory; +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.ecore.EAttribute; +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EPackage; +import org.eclipse.emf.ecore.EReference; +import org.eclipse.emf.ecore.EcorePackage; +import org.eclipse.emf.ecore.impl.EPackageImpl; + +/** + * <!-- begin-user-doc --> + * An implementation of the model <b>Package</b>. + * <!-- end-user-doc --> + * @generated + */ +public class SecurityPackageImpl extends EPackageImpl implements SecurityPackage +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass securityElementEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass realmEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass directoryEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass securityItemEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass roleEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass assigneeEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass groupEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass userEClass = null; + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private EClass userPasswordEClass = null; + + /** + * Creates an instance of the model <b>Package</b>, registered with + * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package + * package URI value. + * <p>Note: the correct way to create the package is via the static + * factory method {@link #init init()}, which also performs + * initialization of the package, or returns the registered package, + * if one already exists. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see org.eclipse.emf.ecore.EPackage.Registry + * @see org.eclipse.emf.cdo.security.SecurityPackage#eNS_URI + * @see #init() + * @generated + */ + private SecurityPackageImpl() + { + super(eNS_URI, SecurityFactory.eINSTANCE); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private static boolean isInited = false; + + /** + * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends. + * + * <p>This method is used to initialize {@link SecurityPackage#eINSTANCE} when that field is accessed. + * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @see #eNS_URI + * @see #createPackageContents() + * @see #initializePackageContents() + * @generated + */ + public static SecurityPackage init() + { + if (isInited) + { + return (SecurityPackage)EPackage.Registry.INSTANCE.getEPackage(SecurityPackage.eNS_URI); + } + + // Obtain or create and register package + SecurityPackageImpl theSecurityPackage = (SecurityPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof SecurityPackageImpl ? EPackage.Registry.INSTANCE + .get(eNS_URI) : new SecurityPackageImpl()); + + isInited = true; + + // Initialize simple dependencies + EtypesPackage.eINSTANCE.eClass(); + + // Create package meta-data objects + theSecurityPackage.createPackageContents(); + + // Initialize created meta-data + theSecurityPackage.initializePackageContents(); + + // Mark meta-data to indicate it can't be changed + theSecurityPackage.freeze(); + + // Update the registry and return the package + EPackage.Registry.INSTANCE.put(SecurityPackage.eNS_URI, theSecurityPackage); + return theSecurityPackage; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getSecurityElement() + { + return securityElementEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getRealm() + { + return realmEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getRealm_Items() + { + return (EReference)realmEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getRealm_Name() + { + return (EAttribute)realmEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getDirectory() + { + return directoryEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getDirectory_Items() + { + return (EReference)directoryEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getDirectory_Name() + { + return (EAttribute)directoryEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getSecurityItem() + { + return securityItemEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getRole() + { + return roleEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getRole_Assignees() + { + return (EReference)roleEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getRole_Id() + { + return (EAttribute)roleEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getRole_Type() + { + return (EAttribute)roleEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getAssignee() + { + return assigneeEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getAssignee_Roles() + { + return (EReference)assigneeEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getAssignee_Id() + { + return (EAttribute)assigneeEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getGroup() + { + return groupEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getGroup_Users() + { + return (EReference)groupEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getGroup_InheritedGroups() + { + return (EReference)groupEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getGroup_InheritingGroups() + { + return (EReference)groupEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getUser() + { + return userEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getUser_Groups() + { + return (EReference)userEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUser_FirstName() + { + return (EAttribute)userEClass.getEStructuralFeatures().get(1); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUser_LastName() + { + return (EAttribute)userEClass.getEStructuralFeatures().get(2); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUser_Email() + { + return (EAttribute)userEClass.getEStructuralFeatures().get(3); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUser_Locked() + { + return (EAttribute)userEClass.getEStructuralFeatures().get(4); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EReference getUser_Password() + { + return (EReference)userEClass.getEStructuralFeatures().get(5); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EClass getUserPassword() + { + return userPasswordEClass; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public EAttribute getUserPassword_Encrypted() + { + return (EAttribute)userPasswordEClass.getEStructuralFeatures().get(0); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityFactory getSecurityFactory() + { + return (SecurityFactory)getEFactoryInstance(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isCreated = false; + + /** + * Creates the meta-model objects for the package. This method is + * guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void createPackageContents() + { + if (isCreated) + { + return; + } + isCreated = true; + + // Create classes and their features + securityElementEClass = createEClass(SECURITY_ELEMENT); + + securityItemEClass = createEClass(SECURITY_ITEM); + + realmEClass = createEClass(REALM); + createEReference(realmEClass, REALM__ITEMS); + createEAttribute(realmEClass, REALM__NAME); + + directoryEClass = createEClass(DIRECTORY); + createEReference(directoryEClass, DIRECTORY__ITEMS); + createEAttribute(directoryEClass, DIRECTORY__NAME); + + roleEClass = createEClass(ROLE); + createEReference(roleEClass, ROLE__ASSIGNEES); + createEAttribute(roleEClass, ROLE__ID); + createEAttribute(roleEClass, ROLE__TYPE); + + assigneeEClass = createEClass(ASSIGNEE); + createEReference(assigneeEClass, ASSIGNEE__ROLES); + createEAttribute(assigneeEClass, ASSIGNEE__ID); + + groupEClass = createEClass(GROUP); + createEReference(groupEClass, GROUP__INHERITED_GROUPS); + createEReference(groupEClass, GROUP__INHERITING_GROUPS); + createEReference(groupEClass, GROUP__USERS); + + userEClass = createEClass(USER); + createEReference(userEClass, USER__GROUPS); + createEAttribute(userEClass, USER__FIRST_NAME); + createEAttribute(userEClass, USER__LAST_NAME); + createEAttribute(userEClass, USER__EMAIL); + createEAttribute(userEClass, USER__LOCKED); + createEReference(userEClass, USER__PASSWORD); + + userPasswordEClass = createEClass(USER_PASSWORD); + createEAttribute(userPasswordEClass, USER_PASSWORD__ENCRYPTED); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + private boolean isInitialized = false; + + /** + * Complete the initialization of the package and its meta-model. This + * method is guarded to have no affect on any invocation but its first. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void initializePackageContents() + { + if (isInitialized) + { + return; + } + isInitialized = true; + + // Initialize package + setName(eNAME); + setNsPrefix(eNS_PREFIX); + setNsURI(eNS_URI); + + // Obtain other dependent packages + EtypesPackage theEtypesPackage = (EtypesPackage)EPackage.Registry.INSTANCE.getEPackage(EtypesPackage.eNS_URI); + EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI); + + // Create type parameters + + // Set bounds for type parameters + + // Add supertypes to classes + securityElementEClass.getESuperTypes().add(theEtypesPackage.getModelElement()); + securityItemEClass.getESuperTypes().add(getSecurityElement()); + realmEClass.getESuperTypes().add(getSecurityElement()); + directoryEClass.getESuperTypes().add(getSecurityItem()); + roleEClass.getESuperTypes().add(getSecurityItem()); + assigneeEClass.getESuperTypes().add(getSecurityItem()); + groupEClass.getESuperTypes().add(getAssignee()); + userEClass.getESuperTypes().add(getAssignee()); + + // Initialize classes and features; add operations and parameters + initEClass(securityElementEClass, SecurityElement.class, + "SecurityElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + + addEOperation(securityElementEClass, getRealm(), "getRealm", 1, 1, IS_UNIQUE, IS_ORDERED); //$NON-NLS-1$ + + initEClass(securityItemEClass, SecurityItem.class, + "SecurityItem", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + + initEClass(realmEClass, Realm.class, "Realm", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getRealm_Items(), + getSecurityItem(), + null, + "items", null, 0, -1, Realm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getRealm_Name(), + theEcorePackage.getEString(), + "name", null, 0, 1, Realm.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(directoryEClass, Directory.class, "Directory", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getDirectory_Items(), + getSecurityItem(), + null, + "items", null, 0, -1, Directory.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getDirectory_Name(), + theEcorePackage.getEString(), + "name", null, 0, 1, Directory.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(roleEClass, Role.class, "Role", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getRole_Assignees(), + getAssignee(), + getAssignee_Roles(), + "assignees", null, 0, -1, Role.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getRole_Id(), + theEcorePackage.getEString(), + "id", null, 0, 1, Role.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getRole_Type(), + theEcorePackage.getEString(), + "type", null, 0, 1, Role.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(assigneeEClass, Assignee.class, "Assignee", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getAssignee_Roles(), + getRole(), + getRole_Assignees(), + "roles", null, 0, -1, Assignee.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getAssignee_Id(), + theEcorePackage.getEString(), + "id", null, 0, 1, Assignee.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(groupEClass, Group.class, "Group", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getGroup_InheritedGroups(), + getGroup(), + getGroup_InheritingGroups(), + "inheritedGroups", null, 0, -1, Group.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference( + getGroup_InheritingGroups(), + getGroup(), + getGroup_InheritedGroups(), + "inheritingGroups", null, 0, -1, Group.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference( + getGroup_Users(), + getUser(), + getUser_Groups(), + "users", null, 0, -1, Group.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(userEClass, User.class, "User", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEReference( + getUser_Groups(), + getGroup(), + getGroup_Users(), + "groups", null, 0, -1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getUser_FirstName(), + theEcorePackage.getEString(), + "firstName", null, 0, 1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getUser_LastName(), + theEcorePackage.getEString(), + "lastName", null, 0, 1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getUser_Email(), + theEcorePackage.getEString(), + "email", null, 0, 1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEAttribute( + getUser_Locked(), + theEcorePackage.getEBoolean(), + "locked", null, 0, 1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference( + getUser_Password(), + getUserPassword(), + null, + "password", null, 0, 1, User.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + initEClass(userPasswordEClass, UserPassword.class, + "UserPassword", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ + initEAttribute( + getUserPassword_Encrypted(), + theEcorePackage.getEString(), + "encrypted", null, 0, 1, UserPassword.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + + // Create resource + createResource(eNS_URI); + } + +} // SecurityPackageImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserImpl.java new file mode 100644 index 0000000000..bca8da5863 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserImpl.java @@ -0,0 +1,173 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.common.util.EList; +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>User</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#getGroups <em>Groups</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#getFirstName <em>First Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#getLastName <em>Last Name</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#getEmail <em>Email</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#isLocked <em>Locked</em>}</li> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserImpl#getPassword <em>Password</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class UserImpl extends AssigneeImpl implements User +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UserImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.USER; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @SuppressWarnings("unchecked") + public EList<Group> getGroups() + { + return (EList<Group>)eGet(SecurityPackage.Literals.USER__GROUPS, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getFirstName() + { + return (String)eGet(SecurityPackage.Literals.USER__FIRST_NAME, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setFirstName(String newFirstName) + { + eSet(SecurityPackage.Literals.USER__FIRST_NAME, newFirstName); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getLastName() + { + return (String)eGet(SecurityPackage.Literals.USER__LAST_NAME, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setLastName(String newLastName) + { + eSet(SecurityPackage.Literals.USER__LAST_NAME, newLastName); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getEmail() + { + return (String)eGet(SecurityPackage.Literals.USER__EMAIL, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setEmail(String newEmail) + { + eSet(SecurityPackage.Literals.USER__EMAIL, newEmail); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public boolean isLocked() + { + return (Boolean)eGet(SecurityPackage.Literals.USER__LOCKED, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setLocked(boolean newLocked) + { + eSet(SecurityPackage.Literals.USER__LOCKED, newLocked); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public UserPassword getPassword() + { + return (UserPassword)eGet(SecurityPackage.Literals.USER__PASSWORD, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setPassword(UserPassword newPassword) + { + eSet(SecurityPackage.Literals.USER__PASSWORD, newPassword); + } + +} // UserImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserPasswordImpl.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserPasswordImpl.java new file mode 100644 index 0000000000..2face8f5d3 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/impl/UserPasswordImpl.java @@ -0,0 +1,87 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.impl; + +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.internal.cdo.CDOObjectImpl; + +import org.eclipse.emf.ecore.EClass; + +/** + * <!-- begin-user-doc --> + * An implementation of the model object '<em><b>User Password</b></em>'. + * <!-- end-user-doc --> + * <p> + * The following features are implemented: + * <ul> + * <li>{@link org.eclipse.emf.cdo.security.impl.UserPasswordImpl#getEncrypted <em>Encrypted</em>}</li> + * </ul> + * </p> + * + * @generated + */ +public class UserPasswordImpl extends CDOObjectImpl implements UserPassword +{ + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected UserPasswordImpl() + { + super(); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected EClass eStaticClass() + { + return SecurityPackage.Literals.USER_PASSWORD; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + @Override + protected int eStaticFeatureCount() + { + return 0; + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public String getEncrypted() + { + return (String)eGet(SecurityPackage.Literals.USER_PASSWORD__ENCRYPTED, true); + } + + /** + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public void setEncrypted(String newEncrypted) + { + eSet(SecurityPackage.Literals.USER_PASSWORD__ENCRYPTED, newEncrypted); + } + +} // UserPasswordImpl diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecurityAdapterFactory.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecurityAdapterFactory.java new file mode 100644 index 0000000000..33737ed051 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecurityAdapterFactory.java @@ -0,0 +1,336 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.util; + +import org.eclipse.emf.cdo.etypes.ModelElement; +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityElement; +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notifier; +import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl; +import org.eclipse.emf.ecore.EObject; + +/** + * <!-- begin-user-doc --> + * The <b>Adapter Factory</b> for the model. + * It provides an adapter <code>createXXX</code> method for each class of the model. + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.SecurityPackage + * @generated + */ +public class SecurityAdapterFactory extends AdapterFactoryImpl +{ + /** + * The cached model package. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SecurityPackage modelPackage; + + /** + * Creates an instance of the adapter factory. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecurityAdapterFactory() + { + if (modelPackage == null) + { + modelPackage = SecurityPackage.eINSTANCE; + } + } + + /** + * Returns whether this factory is applicable for the type of the object. + * <!-- begin-user-doc --> + * This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model. + * <!-- end-user-doc --> + * @return whether this factory is applicable for the type of the object. + * @generated + */ + @Override + public boolean isFactoryForType(Object object) + { + if (object == modelPackage) + { + return true; + } + if (object instanceof EObject) + { + return ((EObject)object).eClass().getEPackage() == modelPackage; + } + return false; + } + + /** + * The switch that delegates to the <code>createXXX</code> methods. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected SecuritySwitch<Adapter> modelSwitch = new SecuritySwitch<Adapter>() + { + @Override + public Adapter caseSecurityElement(SecurityElement object) + { + return createSecurityElementAdapter(); + } + + @Override + public Adapter caseSecurityItem(SecurityItem object) + { + return createSecurityItemAdapter(); + } + + @Override + public Adapter caseRealm(Realm object) + { + return createRealmAdapter(); + } + + @Override + public Adapter caseDirectory(Directory object) + { + return createDirectoryAdapter(); + } + + @Override + public Adapter caseRole(Role object) + { + return createRoleAdapter(); + } + + @Override + public Adapter caseAssignee(Assignee object) + { + return createAssigneeAdapter(); + } + + @Override + public Adapter caseGroup(Group object) + { + return createGroupAdapter(); + } + + @Override + public Adapter caseUser(User object) + { + return createUserAdapter(); + } + + @Override + public Adapter caseUserPassword(UserPassword object) + { + return createUserPasswordAdapter(); + } + + @Override + public Adapter caseModelElement(ModelElement object) + { + return createModelElementAdapter(); + } + + @Override + public Adapter defaultCase(EObject object) + { + return createEObjectAdapter(); + } + }; + + /** + * Creates an adapter for the <code>target</code>. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @param target the object to adapt. + * @return the adapter for the <code>target</code>. + * @generated + */ + @Override + public Adapter createAdapter(Notifier target) + { + return modelSwitch.doSwitch((EObject)target); + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.SecurityElement <em>Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.SecurityElement + * @generated + */ + public Adapter createSecurityElementAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.Realm <em>Realm</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.Realm + * @generated + */ + public Adapter createRealmAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.Directory <em>Directory</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.Directory + * @generated + */ + public Adapter createDirectoryAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.SecurityItem <em>Item</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.SecurityItem + * @generated + */ + public Adapter createSecurityItemAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.Role <em>Role</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.Role + * @generated + */ + public Adapter createRoleAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.Assignee <em>Assignee</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.Assignee + * @generated + */ + public Adapter createAssigneeAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.Group <em>Group</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.Group + * @generated + */ + public Adapter createGroupAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.User <em>User</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.User + * @generated + */ + public Adapter createUserAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.security.UserPassword <em>User Password</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.security.UserPassword + * @generated + */ + public Adapter createUserPasswordAdapter() + { + return null; + } + + /** + * Creates a new adapter for an object of class '{@link org.eclipse.emf.cdo.etypes.ModelElement <em>Model Element</em>}'. + * <!-- begin-user-doc --> + * This default implementation returns null so that we can easily ignore cases; + * it's useful to ignore a case when inheritance will catch all the cases anyway. + * <!-- end-user-doc --> + * @return the new adapter. + * @see org.eclipse.emf.cdo.etypes.ModelElement + * @generated + */ + public Adapter createModelElementAdapter() + { + return null; + } + + /** + * Creates a new adapter for the default case. + * <!-- begin-user-doc --> + * This default implementation returns null. + * <!-- end-user-doc --> + * @return the new adapter. + * @generated + */ + public Adapter createEObjectAdapter() + { + return null; + } + +} // SecurityAdapterFactory diff --git a/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecuritySwitch.java b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecuritySwitch.java new file mode 100644 index 0000000000..0ffc6fb0d9 --- /dev/null +++ b/plugins/org.eclipse.emf.cdo.security/src/org/eclipse/emf/cdo/security/util/SecuritySwitch.java @@ -0,0 +1,469 @@ +/* + * Copyright (c) 2004 - 2012 Eike Stepper (Berlin, Germany) 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: + * Eike Stepper - initial API and implementation + */ +package org.eclipse.emf.cdo.security.util; + +import org.eclipse.emf.cdo.etypes.ModelElement; +import org.eclipse.emf.cdo.security.Assignee; +import org.eclipse.emf.cdo.security.Directory; +import org.eclipse.emf.cdo.security.Group; +import org.eclipse.emf.cdo.security.Realm; +import org.eclipse.emf.cdo.security.Role; +import org.eclipse.emf.cdo.security.SecurityElement; +import org.eclipse.emf.cdo.security.SecurityItem; +import org.eclipse.emf.cdo.security.SecurityPackage; +import org.eclipse.emf.cdo.security.User; +import org.eclipse.emf.cdo.security.UserPassword; + +import org.eclipse.emf.ecore.EClass; +import org.eclipse.emf.ecore.EObject; + +import java.util.List; + +/** + * <!-- begin-user-doc --> + * The <b>Switch</b> for the model's inheritance hierarchy. + * It supports the call {@link #doSwitch(EObject) doSwitch(object)} + * to invoke the <code>caseXXX</code> method for each class of the model, + * starting with the actual class of the object + * and proceeding up the inheritance hierarchy + * until a non-null result is returned, + * which is the result of the switch. + * <!-- end-user-doc --> + * @see org.eclipse.emf.cdo.security.SecurityPackage + * @generated + */ +public class SecuritySwitch<T> +{ + /** + * The cached model package + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + protected static SecurityPackage modelPackage; + + /** + * Creates an instance of the switch. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @generated + */ + public SecuritySwitch() + { + if (modelPackage == null) + { + modelPackage = SecurityPackage.eINSTANCE; + } + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + public T doSwitch(EObject theEObject) + { + return doSwitch(theEObject.eClass(), theEObject); + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + protected T doSwitch(EClass theEClass, EObject theEObject) + { + if (theEClass.eContainer() == modelPackage) + { + return doSwitch(theEClass.getClassifierID(), theEObject); + } + else + { + List<EClass> eSuperTypes = theEClass.getESuperTypes(); + return eSuperTypes.isEmpty() ? defaultCase(theEObject) : doSwitch(eSuperTypes.get(0), theEObject); + } + } + + /** + * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. + * <!-- begin-user-doc --> + * <!-- end-user-doc --> + * @return the first non-null result returned by a <code>caseXXX</code> call. + * @generated + */ + protected T doSwitch(int classifierID, EObject theEObject) + { + switch (classifierID) + { + case SecurityPackage.SECURITY_ELEMENT: + { + SecurityElement securityElement = (SecurityElement)theEObject; + T result = caseSecurityElement(securityElement); + if (result == null) + { + result = caseModelElement(securityElement); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.SECURITY_ITEM: + { + SecurityItem securityItem = (SecurityItem)theEObject; + T result = caseSecurityItem(securityItem); + if (result == null) + { + result = caseSecurityElement(securityItem); + } + if (result == null) + { + result = caseModelElement(securityItem); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.REALM: + { + Realm realm = (Realm)theEObject; + T result = caseRealm(realm); + if (result == null) + { + result = caseSecurityElement(realm); + } + if (result == null) + { + result = caseModelElement(realm); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.DIRECTORY: + { + Directory directory = (Directory)theEObject; + T result = caseDirectory(directory); + if (result == null) + { + result = caseSecurityItem(directory); + } + if (result == null) + { + result = caseSecurityElement(directory); + } + if (result == null) + { + result = caseModelElement(directory); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.ROLE: + { + Role role = (Role)theEObject; + T result = caseRole(role); + if (result == null) + { + result = caseSecurityItem(role); + } + if (result == null) + { + result = caseSecurityElement(role); + } + if (result == null) + { + result = caseModelElement(role); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.ASSIGNEE: + { + Assignee assignee = (Assignee)theEObject; + T result = caseAssignee(assignee); + if (result == null) + { + result = caseSecurityItem(assignee); + } + if (result == null) + { + result = caseSecurityElement(assignee); + } + if (result == null) + { + result = caseModelElement(assignee); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.GROUP: + { + Group group = (Group)theEObject; + T result = caseGroup(group); + if (result == null) + { + result = caseAssignee(group); + } + if (result == null) + { + result = caseSecurityItem(group); + } + if (result == null) + { + result = caseSecurityElement(group); + } + if (result == null) + { + result = caseModelElement(group); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.USER: + { + User user = (User)theEObject; + T result = caseUser(user); + if (result == null) + { + result = caseAssignee(user); + } + if (result == null) + { + result = caseSecurityItem(user); + } + if (result == null) + { + result = caseSecurityElement(user); + } + if (result == null) + { + result = caseModelElement(user); + } + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + case SecurityPackage.USER_PASSWORD: + { + UserPassword userPassword = (UserPassword)theEObject; + T result = caseUserPassword(userPassword); + if (result == null) + { + result = defaultCase(theEObject); + } + return result; + } + default: + return defaultCase(theEObject); + } + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseSecurityElement(SecurityElement object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Realm</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Realm</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRealm(Realm object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Directory</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Directory</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseDirectory(Directory object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Item</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Item</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseSecurityItem(SecurityItem object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Role</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Role</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseRole(Role object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Assignee</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Assignee</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseAssignee(Assignee object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Group</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Group</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseGroup(Group object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>User</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>User</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseUser(User object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>User Password</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>User Password</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseUserPassword(UserPassword object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>Model Element</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>Model Element</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) + * @generated + */ + public T caseModelElement(ModelElement object) + { + return null; + } + + /** + * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. + * <!-- begin-user-doc --> + * This implementation returns null; + * returning a non-null result will terminate the switch, but this is the last case anyway. + * <!-- end-user-doc --> + * @param object the target of the switch. + * @return the result of interpreting the object as an instance of '<em>EObject</em>'. + * @see #doSwitch(org.eclipse.emf.ecore.EObject) + * @generated + */ + public T defaultCase(EObject object) + { + return null; + } + +} // SecuritySwitch diff --git a/plugins/org.eclipse.emf.cdo/model/etypes.ecore b/plugins/org.eclipse.emf.cdo/model/etypes.ecore index 31ff1f2d2b..c3445df273 100644 --- a/plugins/org.eclipse.emf.cdo/model/etypes.ecore +++ b/plugins/org.eclipse.emf.cdo/model/etypes.ecore @@ -1,29 +1,28 @@ -<?xml version="1.0" encoding="UTF-8"?>
-<ecore:EPackage xmi:version="2.0"
- xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="etypes"
- nsURI="http://www.eclipse.org/emf/CDO/Etypes/4.0.0" nsPrefix="etypes">
- <eClassifiers xsi:type="ecore:EDataType" name="Blob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOBlob"/>
- <eClassifiers xsi:type="ecore:EDataType" name="Clob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOClob"/>
- <eClassifiers xsi:type="ecore:EClass" name="ModelElement" abstract="true">
- <eOperations name="getAnnotation" eType="#//Annotation">
- <eParameters name="source" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/>
- </eOperations>
- <eStructuralFeatures xsi:type="ecore:EReference" name="annotations" upperBound="-1"
- eType="#//Annotation" containment="true" eOpposite="#//Annotation/modelElement"/>
- </eClassifiers>
- <eClassifiers xsi:type="ecore:EClass" name="Annotation" eSuperTypes="#//ModelElement">
- <eStructuralFeatures xsi:type="ecore:EAttribute" name="source" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/>
- <eStructuralFeatures xsi:type="ecore:EReference" name="details" upperBound="-1"
- eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EStringToStringMapEntry"
- containment="true" resolveProxies="false"/>
- <eStructuralFeatures xsi:type="ecore:EReference" name="modelElement" eType="#//ModelElement"
- eOpposite="#//ModelElement/annotations"/>
- <eStructuralFeatures xsi:type="ecore:EReference" name="contents" upperBound="-1"
- eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EObject"
- containment="true" resolveProxies="false"/>
- <eStructuralFeatures xsi:type="ecore:EReference" name="references" upperBound="-1"
- eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EObject"/>
- </eClassifiers>
- <eClassifiers xsi:type="ecore:EDataType" name="Lob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOLob"/>
-</ecore:EPackage>
+<?xml version="1.0" encoding="UTF-8"?> +<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="etypes" nsURI="http://www.eclipse.org/emf/CDO/Etypes/4.0.0" + nsPrefix="etypes"> + <eClassifiers xsi:type="ecore:EDataType" name="Blob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOBlob"/> + <eClassifiers xsi:type="ecore:EDataType" name="Clob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOClob"/> + <eClassifiers xsi:type="ecore:EClass" name="ModelElement" abstract="true"> + <eOperations name="getAnnotation" eType="#//Annotation"> + <eParameters name="source" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + </eOperations> + <eStructuralFeatures xsi:type="ecore:EReference" name="annotations" upperBound="-1" + eType="#//Annotation" containment="true" eOpposite="#//Annotation/modelElement"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EClass" name="Annotation" eSuperTypes="#//ModelElement"> + <eStructuralFeatures xsi:type="ecore:EAttribute" name="source" eType="ecore:EDataType platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EString"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="details" upperBound="-1" + eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EStringToStringMapEntry" + containment="true" resolveProxies="false"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="modelElement" eType="#//ModelElement" + eOpposite="#//ModelElement/annotations"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="contents" upperBound="-1" + eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EObject" + containment="true" resolveProxies="false"/> + <eStructuralFeatures xsi:type="ecore:EReference" name="references" upperBound="-1" + eType="ecore:EClass platform:/plugin/org.eclipse.emf.ecore/model/Ecore.ecore#//EObject"/> + </eClassifiers> + <eClassifiers xsi:type="ecore:EDataType" name="Lob" instanceClassName="org.eclipse.emf.cdo.common.lob.CDOLob"/> +</ecore:EPackage> |