From 75a95db23e0a4bf683519603cb3ca7dd97ad11bc Mon Sep 17 00:00:00 2001 From: lukaseder Date: Thu, 26 Feb 2015 19:09:43 +0100 Subject: [PATCH] [#4101] Cleanup and revert of previous funky commit --- .project | 17 - .settings/org.eclipse.m2e.core.prefs | 4 - .../org.eclipse.core.resources.prefs | 4 - .../.settings/org.eclipse.jdt.core.prefs | 382 ------------------ .../.settings/org.eclipse.jdt.ui.prefs | 116 ------ .../.settings/org.eclipse.m2e.core.prefs | 4 - .../.settings/org.maven.ide.eclipse.prefs | 8 - .../jOOQ-codegen-gradle/example/README.md | 7 - .../jOOQ-codegen-gradle/example/build.gradle | 78 ---- .../gradle/wrapper/gradle-wrapper.properties | 6 - .../jOOQ-codegen-gradle/example/gradlew | 164 -------- .../jOOQ-codegen-gradle/example/gradlew.bat | 90 ----- .../example/settings.gradle | 1 - .../src/main/java/example/JooqModule.java | 55 --- .../resources/db/migration/V1__Add_table.sql | 7 - .../src/test/java/example/H2Module.java | 50 --- .../src/test/java/example/JooqTest.java | 102 ----- .../example/src/test/java/example/Name.java | 69 ---- .../example/src/test/java/example/User.java | 73 ---- jOOQ-examples/jOOQ-codegen-gradle/pom.xml | 75 ---- .../jooq/util/gradle/GenerateJooqTask.groovy | 86 ---- .../org/jooq/util/gradle/JooqExtension.groovy | 79 ---- .../org/jooq/util/gradle/JooqPlugin.groovy | 53 --- .../META-INF/gradle-plugins/jooq.properties | 1 - .../java/org/jooq/example/test/settings.js | 33 -- .../org/jooq/example/test/simple-query.js | 16 - .../org/jooq/example/QueriesWithTypes.java | 180 --------- .../pg_catalog/routines/PgCursor.java | 101 ----- jOOQ-meta/src/main/resources/xjb/binding.xjb | 27 -- .../release/template/RELEASE-NOTES.txt.regex | 16 - .../java/org/jooq/impl/AbstractSelect.java | 180 --------- .../main/java/org/jooq/impl/DefaultArray.java | 115 ------ .../java/org/jooq/impl/ExistsOperator.java | 63 --- .../main/java/org/jooq/impl/SQLTemplate.java | 96 ----- .../impl/SelectQueryAsExistsCondition.java | 102 ----- .../org/jooq/impl/SelectQueryAsField.java | 94 ----- .../impl/SelectQueryAsSubQueryCondition.java | 107 ----- .../org/jooq/impl/SelectQueryAsTable.java | 115 ------ jOOQ/src/main/java/org/jooq/impl/Union.java | 155 ------- jOOQ/src/main/resources/xsd/jooq-pro.xsd | 12 - 40 files changed, 2943 deletions(-) delete mode 100644 .project delete mode 100644 .settings/org.eclipse.m2e.core.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.core.resources.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.core.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.ui.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.m2e.core.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/.settings/org.maven.ide.eclipse.prefs delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/README.md delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/build.gradle delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/gradle/wrapper/gradle-wrapper.properties delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/gradlew delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/gradlew.bat delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/settings.gradle delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/main/java/example/JooqModule.java delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/main/resources/db/migration/V1__Add_table.sql delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/H2Module.java delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/JooqTest.java delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/Name.java delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/User.java delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/pom.xml delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/GenerateJooqTask.groovy delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqExtension.groovy delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqPlugin.groovy delete mode 100644 jOOQ-examples/jOOQ-codegen-gradle/src/main/resources/META-INF/gradle-plugins/jooq.properties delete mode 100644 jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/settings.js delete mode 100644 jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/simple-query.js delete mode 100644 jOOQ-examples/jOOQ-oracle-example/src/test/java/org/jooq/example/QueriesWithTypes.java delete mode 100644 jOOQ-meta/src/main/java/org/jooq/util/postgres/pg_catalog/routines/PgCursor.java delete mode 100644 jOOQ-meta/src/main/resources/xjb/binding.xjb delete mode 100644 jOOQ-release/release/template/RELEASE-NOTES.txt.regex delete mode 100644 jOOQ/src/main/java/org/jooq/impl/AbstractSelect.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/DefaultArray.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/ExistsOperator.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/SQLTemplate.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/SelectQueryAsExistsCondition.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/SelectQueryAsField.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/SelectQueryAsSubQueryCondition.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/SelectQueryAsTable.java delete mode 100644 jOOQ/src/main/java/org/jooq/impl/Union.java delete mode 100644 jOOQ/src/main/resources/xsd/jooq-pro.xsd diff --git a/.project b/.project deleted file mode 100644 index 9b18eae186..0000000000 --- a/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - jOOQ - - - - - - org.eclipse.m2e.core.maven2Builder - - - - - - org.eclipse.m2e.core.maven2Nature - - diff --git a/.settings/org.eclipse.m2e.core.prefs b/.settings/org.eclipse.m2e.core.prefs deleted file mode 100644 index 14b697b7bb..0000000000 --- a/.settings/org.eclipse.m2e.core.prefs +++ /dev/null @@ -1,4 +0,0 @@ -activeProfiles= -eclipse.preferences.version=1 -resolveWorkspaceProjects=true -version=1 diff --git a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.core.resources.prefs b/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.core.resources.prefs deleted file mode 100644 index abdea9ac03..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.core.resources.prefs +++ /dev/null @@ -1,4 +0,0 @@ -eclipse.preferences.version=1 -encoding//src/main/java=UTF-8 -encoding//src/main/resources=UTF-8 -encoding/=UTF-8 diff --git a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.core.prefs b/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 1a96ea842a..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,382 +0,0 @@ -eclipse.preferences.version=1 -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.6 -org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.6 -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.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=disabled -org.eclipse.jdt.core.compiler.problem.discouragedReference=warning -org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore -org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore -org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled -org.eclipse.jdt.core.compiler.problem.fieldHiding=warning -org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning -org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning -org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning -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=enabled -org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled -org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected -org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning -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=ignore -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=all_standard_tags -org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore -org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled -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=error -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=warning -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=warning -org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning -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=warning -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.6 -org.eclipse.jdt.core.formatter.align_type_members_on_columns=true -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=49 -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_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.blank_lines_after_imports=1 -org.eclipse.jdt.core.formatter.blank_lines_after_package=1 -org.eclipse.jdt.core.formatter.blank_lines_before_field=0 -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=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line -org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_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=true -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=do not insert -org.eclipse.jdt.core.formatter.comment.line_length=80 -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=1 -org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=1 -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=true -org.eclipse.jdt.core.formatter.indentation.size=4 -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=insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=do not 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=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_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_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_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_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_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=4 -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_outer_expressions_when_nested=true diff --git a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.ui.prefs b/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.ui.prefs deleted file mode 100644 index dd830b12b7..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.jdt.ui.prefs +++ /dev/null @@ -1,116 +0,0 @@ -#Sat Nov 05 13:02:50 CET 2011 -cleanup.add_default_serial_version_id=false -cleanup.add_generated_serial_version_id=true -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=true -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=false -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=true -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=false -cleanup.use_this_for_non_static_field_access=false -cleanup.use_this_for_non_static_field_access_only_if_necessary=false -cleanup.use_this_for_non_static_method_access=false -cleanup.use_this_for_non_static_method_access_only_if_necessary=true -cleanup_profile=_jOOQ -cleanup_settings_version=2 -eclipse.preferences.version=1 -editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true -formatter_profile=_jOOQ -formatter_settings_version=12 -org.eclipse.jdt.ui.ignorelowercasenames=true -org.eclipse.jdt.ui.importorder=java;javax;org.jooq;org;com; -org.eclipse.jdt.ui.javadoc=false -org.eclipse.jdt.ui.ondemandthreshold=99 -org.eclipse.jdt.ui.staticondemandthreshold=99 -org.eclipse.jdt.ui.text.custom_code_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=true -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=false -sp_cleanup.format_source_code=false -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=false -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=false -sp_cleanup.use_blocks_only_for_return_and_throw=false -sp_cleanup.use_parentheses_in_expressions=false -sp_cleanup.use_this_for_non_static_field_access=false -sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true -sp_cleanup.use_this_for_non_static_method_access=false -sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.m2e.core.prefs b/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.m2e.core.prefs deleted file mode 100644 index f897a7f1cb..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.eclipse.m2e.core.prefs +++ /dev/null @@ -1,4 +0,0 @@ -activeProfiles= -eclipse.preferences.version=1 -resolveWorkspaceProjects=true -version=1 diff --git a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.maven.ide.eclipse.prefs b/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.maven.ide.eclipse.prefs deleted file mode 100644 index 5c76a93562..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/.settings/org.maven.ide.eclipse.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Sun Apr 10 10:40:24 CEST 2011 -activeProfiles= -eclipse.preferences.version=1 -fullBuildGoals=process-test-resources -resolveWorkspaceProjects=true -resourceFilterGoals=process-resources resources\:testResources -skipCompilerPlugin=true -version=1 diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/README.md b/jOOQ-examples/jOOQ-codegen-gradle/example/README.md deleted file mode 100644 index 6026cf06da..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/README.md +++ /dev/null @@ -1,7 +0,0 @@ -This example shows how to combine jOOQ, [Flyway](http://flywaydb.org) database migrations, and the -[H2](http://www.h2database.com) embedded database to code generate during the build. This approach -allows developers to avoid checking generated code into source control and supports Gradle's -incremental building. The process optionally supports schema per project for service isolation. At -application runtime a traditional database can be used, such as Postgres, using the generated jOOQ -models. An alternative mapping library, [ModelMapper](http://modelmapper.org), is used to -demonstrate automatically projecting the record into a complex model. diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/build.gradle b/jOOQ-examples/jOOQ-codegen-gradle/example/build.gradle deleted file mode 100644 index 2e3381dd46..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/build.gradle +++ /dev/null @@ -1,78 +0,0 @@ -apply plugin: 'java' -apply plugin: 'jooq' -apply plugin: 'flyway' - -buildscript { - repositories { - mavenLocal() - mavenCentral() - } - - dependencies { - classpath 'com.h2database:h2:1.3.170' - classpath 'com.github.ben-manes:gradle-flyway-plugin:0.6' - classpath 'org.jooq:jooq-codegen-gradle:latest.integration' - } -} - -repositories { - mavenCentral() -} - -dependencies { - compile 'org.jooq:jooq:3.1.0' - compile 'com.google.guava:guava:14.0' - compile 'com.google.inject:guice:3.0' - - testCompile 'com.h2database:h2:1.3.170' - testCompile 'org.hamcrest:hamcrest-all:1.3' - testCompile 'org.modelmapper:modelmapper:0.5.5' - testCompile 'com.googlecode.flyway:flyway-core:2.1' - testCompile dependencies.create('org.testng:testng:6.8') { - exclude group: 'junit' - } -} - -test { - useTestNG() -} - -generateJooq.dependsOn(flywayMigrate) -compileJava.dependsOn(generateJooq) - -flyway { - databases { - main { - url = "jdbc:h2:${buildDir}/db/flyway" - schemas = [ 'example' ] - user = 'su' - } - } -} - -generateJooq { - outputs.upToDateWhen { - !flywayMigrate.didWork - } -} - -jooq { - jdbc { - url "jdbc:h2:${buildDir}/db/flyway" - driver 'org.h2.Driver' - user 'su' - } - generator { - database { - name 'org.jooq.util.h2.H2Database' - inputSchema 'example' - includes '.*' - } - generate { - deprecated false - } - target { - packageName 'example.generated' - } - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/gradle/wrapper/gradle-wrapper.properties b/jOOQ-examples/jOOQ-codegen-gradle/example/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index a0f8de8b06..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,6 +0,0 @@ -#Tue Jul 02 12:36:46 PDT 2013 -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists -distributionUrl=http\://services.gradle.org/distributions/gradle-1.6-bin.zip diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew b/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew deleted file mode 100644 index 91a7e269e1..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew +++ /dev/null @@ -1,164 +0,0 @@ -#!/usr/bin/env bash - -############################################################################## -## -## Gradle start up script for UN*X -## -############################################################################## - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS="" - -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" - -warn ( ) { - echo "$*" -} - -die ( ) { - echo - echo "$*" - echo - exit 1 -} - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; -esac - -# For Cygwin, ensure paths are in UNIX format before anything is touched. -if $cygwin ; then - [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"` -fi - -# Attempt to set APP_HOME -# Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi -done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >&- -APP_HOME="`pwd -P`" -cd "$SAVED" >&- - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" - else - JAVACMD="$JAVA_HOME/bin/java" - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD="java" - which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." -fi - -# Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi -fi - -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi - -# For Cygwin, switch paths to Windows format before running java -if $cygwin ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi - # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" - fi - i=$((i+1)) - done - case $i in - (0) set -- ;; - (1) set -- "$args0" ;; - (2) set -- "$args0" "$args1" ;; - (3) set -- "$args0" "$args1" "$args2" ;; - (4) set -- "$args0" "$args1" "$args2" "$args3" ;; - (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac -fi - -# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules -function splitJvmOpts() { - JVM_OPTS=("$@") -} -eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS -JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME" - -exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@" diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew.bat b/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew.bat deleted file mode 100644 index 8a0b282aa6..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/gradlew.bat +++ /dev/null @@ -1,90 +0,0 @@ -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS= - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto init - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto init - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:init -@rem Get command-line arguments, handling Windowz variants - -if not "%OS%" == "Windows_NT" goto win9xME_args -if "%@eval[2+2]" == "4" goto 4NT_args - -:win9xME_args -@rem Slurp the command line arguments. -set CMD_LINE_ARGS= -set _SKIP=2 - -:win9xME_args_slurp -if "x%~1" == "x" goto execute - -set CMD_LINE_ARGS=%* -goto execute - -:4NT_args -@rem Get arguments from the 4NT Shell from JP Software -set CMD_LINE_ARGS=%$ - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/settings.gradle b/jOOQ-examples/jOOQ-codegen-gradle/example/settings.gradle deleted file mode 100644 index dec58e646b..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/settings.gradle +++ /dev/null @@ -1 +0,0 @@ -rootProject.name = 'gradle-jooq-example' diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/java/example/JooqModule.java b/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/java/example/JooqModule.java deleted file mode 100644 index 38b9e6f71e..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/java/example/JooqModule.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright 2013 Ben Manes. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package example; - -import javax.sql.DataSource; - -import com.google.inject.AbstractModule; -import com.google.inject.Provides; -import com.google.inject.Singleton; -import org.jooq.DSLContext; -import org.jooq.SQLDialect; -import org.jooq.conf.Settings; -import org.jooq.impl.DSL; - -import static com.google.common.base.Preconditions.checkNotNull; - -/** - * A module that configures JOOQ. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -public final class JooqModule extends AbstractModule { - private final SQLDialect dialect; - private final Settings setting; - - public JooqModule() { - this(SQLDialect.H2, new Settings().withRenderSchema(false)); - } - - public JooqModule(SQLDialect dialect, Settings setting) { - this.dialect = checkNotNull(dialect); - this.setting = checkNotNull(setting); - } - - @Override - protected void configure() {} - - @Provides @Singleton - DSLContext providesDSLContext(DataSource dataSource) { - return DSL.using(dataSource, dialect, setting); - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/resources/db/migration/V1__Add_table.sql b/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/resources/db/migration/V1__Add_table.sql deleted file mode 100644 index 379faae7f0..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/main/resources/db/migration/V1__Add_table.sql +++ /dev/null @@ -1,7 +0,0 @@ -CREATE TABLE user ( - id INT PRIMARY KEY AUTO_INCREMENT, - first_name VARCHAR(255) NOT NULL, - last_name VARCHAR(255) NOT NULL -); - -CREATE UNIQUE INDEX name_idx ON user (first_name, last_name); diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/H2Module.java b/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/H2Module.java deleted file mode 100644 index 3e9f616b20..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/H2Module.java +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Copyright 2013 Ben Manes. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package example; - -import java.util.concurrent.atomic.AtomicInteger; - -import javax.sql.DataSource; - -import com.google.inject.AbstractModule; -import com.google.inject.Provides; -import com.googlecode.flyway.core.Flyway; -import org.h2.jdbcx.JdbcDataSource; - -/** - * A module that configures the H2 data source. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -public class H2Module extends AbstractModule { - private static final String URL = "jdbc:h2:mem:test_%d;DB_CLOSE_DELAY=-1"; - private static final AtomicInteger counter = new AtomicInteger(); - - @Override - protected void configure() {} - - @Provides - DataSource providesDataSource() { - JdbcDataSource dataSource = new JdbcDataSource(); - dataSource.setURL(String.format(URL, counter.incrementAndGet())); - - Flyway flyway = new Flyway(); - flyway.setDataSource(dataSource); - flyway.migrate(); - - return dataSource; - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/JooqTest.java b/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/JooqTest.java deleted file mode 100644 index 2eae01cde9..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/JooqTest.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2013 Ben Manes. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package example; - -import java.util.List; - -import com.google.inject.Inject; -import example.generated.tables.records.UserRecord; -import org.jooq.DSLContext; -import org.jooq.Record; -import org.jooq.RecordMapper; -import org.modelmapper.ModelMapper; -import org.testng.annotations.AfterMethod; -import org.testng.annotations.BeforeClass; -import org.testng.annotations.Guice; -import org.testng.annotations.Test; - -import static example.generated.tables.User.USER; -import static org.hamcrest.MatcherAssert.assertThat; -import static org.hamcrest.Matchers.contains; -import static org.hamcrest.Matchers.is; - -/** - * @author Ben Manes (ben.manes@gmail.com) - */ -@Guice(modules = {JooqModule.class, H2Module.class}) -public final class JooqTest { - @Inject DSLContext db; - @Inject ModelMapper mapper; - RecordMapper recordMapper; - - @BeforeClass - public void beforeClass() { - recordMapper = new RecordMapper() { - @Override public User map(Record record) { - return mapper.map(record, User.class); - } - }; - } - - @AfterMethod - public void afterMethod() { - db.truncate(USER).execute(); - } - - @Test - public void select() { - User john = insertUser("John", "Doe"); - User user = db.selectFrom(USER) - .where(USER.FIRST_NAME.equal("John")) - .fetchOne().map(recordMapper); - assertThat(user, is(john)); - } - - @Test - public void selectAll() { - User john = insertUser("John", "Doe"); - User jane = insertUser("Jane", "Doe"); - List users = db.selectFrom(USER).fetch().map(recordMapper); - assertThat(users, contains(john, jane)); - } - - @Test - public void insert() { - User john = insertUser("John", "Doe"); - assertThat(john.getId(), is(1)); - } - - @Test - public void update() { - User jane = insertUser("Jane", "Doe"); - jane.getName().setLastName("Smith"); - - UserRecord record = mapper.map(jane, UserRecord.class); - db.executeUpdate(record); - - User user = db.selectFrom(USER) - .where(USER.LAST_NAME.equal("Smith")) - .fetchOne().map(recordMapper); - assertThat(user, is(jane)); - } - - private User insertUser(String firstName, String lastName) { - UserRecord record = new UserRecord(); - record.setFirstName(firstName); - record.setLastName(lastName); - return db.insertInto(USER).set(record).returning().fetchOne().map(recordMapper); - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/Name.java b/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/Name.java deleted file mode 100644 index 54601bbb10..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/Name.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * Copyright 2013 Ben Manes. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package example; - -import com.google.common.base.Objects; - -/** - * The application model of a user's name. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -public final class Name { - private String firstName; - private String lastName; - - public String getFirstName() { - return firstName; - } - - public void setFirstName(String firstName) { - this.firstName = firstName; - } - - public String getLastName() { - return lastName; - } - - public void setLastName(String lastName) { - this.lastName = lastName; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } else if (!(o instanceof Name)) { - return false; - } - Name name = (Name) o; - return Objects.equal(firstName, name.firstName) - && Objects.equal(lastName, name.lastName); - } - - @Override - public int hashCode() { - return Objects.hashCode(firstName, lastName); - } - - @Override - public String toString() { - return Objects.toStringHelper(this) - .add("firstName", firstName) - .add("lastName", lastName) - .toString(); - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/User.java b/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/User.java deleted file mode 100644 index 0ed2817bd0..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/example/src/test/java/example/User.java +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright 2013 Ben Manes. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package example; - -import com.google.common.base.Objects; - -/** - * The application model of a user. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -final class User { - private Name name; - private int id; - - public User() { - this.name = new Name(); - } - - public int getId() { - return id; - } - - public void setId(int id) { - this.id = id; - } - - public Name getName() { - return name; - } - - public void setName(Name name) { - this.name = name; - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } else if (!(o instanceof User)) { - return false; - } - User user = (User) o; - return Objects.equal(id, user.id) - && Objects.equal(name, user.name); - } - - @Override - public int hashCode() { - return Objects.hashCode(name); - } - - @Override - public String toString() { - return Objects.toStringHelper(this) - .add("id", id) - .add("name", name) - .toString(); - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/pom.xml b/jOOQ-examples/jOOQ-codegen-gradle/pom.xml deleted file mode 100644 index 7deee63620..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/pom.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - 4.0.0 - - - org.jooq - jooq-parent - 3.3.0-SNAPSHOT - - - jooq-codegen-gradle - jOOQ Codegen Gradle - - - src/main/groovy - - - maven-compiler-plugin - 3.1 - - groovy-eclipse-compiler - - - - org.codehaus.groovy - groovy-eclipse-compiler - 2.8.0-01 - - - org.codehaus.groovy - groovy-eclipse-batch - 1.8.6-01 - - - - - - - - - org.jooq - jooq-codegen - - - org.jooq - jooq-meta - - - org.codehaus.groovy - groovy-all - 1.8.6 - provided - - - org.gradle - gradle-core - ${version.gradle} - provided - - - org.gradle - gradle-base-services - ${version.gradle} - provided - - - org.gradle - gradle-base-services-groovy - ${version.gradle} - provided - - - diff --git a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/GenerateJooqTask.groovy b/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/GenerateJooqTask.groovy deleted file mode 100644 index 6684460e28..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/GenerateJooqTask.groovy +++ /dev/null @@ -1,86 +0,0 @@ -/** - * Copyright (c) 2009-2013, Lukas Eder, lukas.eder@gmail.com - * All rights reserved. - * - * This software is licensed to you under the Apache License, Version 2.0 - * (the "License"); You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * . Redistributions of source code must retain the above copyright notice, this - * list of conditions and the following disclaimer. - * - * . Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * . Neither the name "jOOQ" nor the names of its contributors may be - * used to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - */ -package org.jooq.util.gradle - -import org.gradle.api.DefaultTask -import org.gradle.api.tasks.TaskAction -import org.jooq.util.GenerationTool -import org.jooq.util.jaxb.Generator -import org.jooq.util.jaxb.Target - -/** - * A task that performs jOOQ code generation. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -class GenerateJooqTask extends DefaultTask { - def configuration - - GenerateJooqTask() { - description = 'Generates jOOQ Java classes.' - group = 'Build' - - project.afterEvaluate { - parseConfiguration() - outputs.dir configuration.generator.target.directory - project.sourceSets.main.java.srcDirs += [ configuration.generator.target.directory ] - } - } - - @TaskAction - def generateJooq() { - logger.info 'Using this configuration:\n{}', project.jooq.xml - GenerationTool.main(configuration); - } - - def parseConfiguration() { - configuration = GenerationTool.load(new ByteArrayInputStream(project.jooq.xml.getBytes('utf8'))) - if (useDefaultTargetDirectory()) { - gradleTargertDir() - } - } - - def useDefaultTargetDirectory() { - def parsed = new XmlParser().parseText(project.jooq.xml) - parsed.generator.target.directory.text().isEmpty() - } - - def gradleTargertDir() { - configuration.generator = configuration.generator ?: new Generator() - configuration.generator.target = configuration.generator.target ?: new Target() - configuration.generator.target.directory = "${project.buildDir}/generated-sources/jooq" - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqExtension.groovy b/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqExtension.groovy deleted file mode 100644 index 75a4cc61d7..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqExtension.groovy +++ /dev/null @@ -1,79 +0,0 @@ -/** - * Copyright (c) 2009-2013, Lukas Eder, lukas.eder@gmail.com - * All rights reserved. - * - * This software is licensed to you under the Apache License, Version 2.0 - * (the "License"); You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * . Redistributions of source code must retain the above copyright notice, this - * list of conditions and the following disclaimer. - * - * . Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * . Neither the name "jOOQ" nor the names of its contributors may be - * used to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - */ -package org.jooq.util.gradle - -import groovy.xml.MarkupBuilder - -/** - * The configuration as an XML DSL matching jOOQ's schema. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -public class JooqExtension { - private def builder - private def printer - private def writer - private def done - - public JooqExtension() { - writer = new StringWriter() - printer = new IndentPrinter(writer) - builder = new MarkupBuilder(printer) - start() - } - - private def start() { - printer.incrementIndent() - printer.println('') - printer.printIndent() - } - - private def end() { - if (!done) { - done = true - printer.println('\n') - } - } - - def methodMissing(String name, args) { - builder.invokeMethod(name, args) - } - - def getXml() { - end() - writer.toString() - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqPlugin.groovy b/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqPlugin.groovy deleted file mode 100644 index 4b8d70ffcd..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/src/main/groovy/org/jooq/util/gradle/JooqPlugin.groovy +++ /dev/null @@ -1,53 +0,0 @@ -/** - * Copyright (c) 2009-2013, Lukas Eder, lukas.eder@gmail.com - * All rights reserved. - * - * This software is licensed to you under the Apache License, Version 2.0 - * (the "License"); You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * . Redistributions of source code must retain the above copyright notice, this - * list of conditions and the following disclaimer. - * - * . Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * . Neither the name "jOOQ" nor the names of its contributors may be - * used to endorse or promote products derived from this software without - * specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - */ -package org.jooq.util.gradle; - -import org.gradle.api.Plugin -import org.gradle.api.Project - -/** - * Registers the plugin's tasks. - * - * @author Ben Manes (ben.manes@gmail.com) - */ -public class JooqPlugin implements Plugin { - - @Override - public void apply(Project project) { - project.extensions.create('jooq', JooqExtension) - project.tasks.create('generateJooq', GenerateJooqTask) - } -} diff --git a/jOOQ-examples/jOOQ-codegen-gradle/src/main/resources/META-INF/gradle-plugins/jooq.properties b/jOOQ-examples/jOOQ-codegen-gradle/src/main/resources/META-INF/gradle-plugins/jooq.properties deleted file mode 100644 index 7dca65417e..0000000000 --- a/jOOQ-examples/jOOQ-codegen-gradle/src/main/resources/META-INF/gradle-plugins/jooq.properties +++ /dev/null @@ -1 +0,0 @@ -implementation-class=org.jooq.util.gradle.JooqPlugin diff --git a/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/settings.js b/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/settings.js deleted file mode 100644 index 1bc5c3a411..0000000000 --- a/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/settings.js +++ /dev/null @@ -1,33 +0,0 @@ -var DSL = Java.type("org.jooq.impl.DSL"); -var Settings = Java.type("org.jooq.conf.Settings"); -var RenderNameStyle = Java.type("org.jooq.conf.RenderNameStyle"); - -var Assert = Java.type("org.junit.Assert"); -var Arrays = Java.type("java.util.Arrays"); - -var Tables = Java.type("org.jooq.example.db.h2.Tables"); -var b = Tables.BOOK; -var a = Tables.AUTHOR; - - -// Unfortunately, there is a Nashorn / Java interoperablility issue documented here: -// http://stackoverflow.com/q/25603191/521799 -// -// To work around this issue, tables should probably be supplied in JavaScript arrays, -// in order to explicitly invoke the method accepting varargs, instead of the overloaded method - -var authors = DSL.using(connection, new Settings().withRenderNameStyle(RenderNameStyle.AS_IS)) - .select(a.ID) - .from([a]) - .orderBy(a.ID) - .fetch(a.ID); - -Assert.assertEquals(Arrays.asList([1, 2]), authors); - -var authors = DSL.using(connection, new Settings().withRenderNameStyle(RenderNameStyle.AS_IS)) - .select(a.ID) - .from([DSL.tableByName("author")]) - .orderBy(a.ID) - .fetch(a.ID); - -Assert.assertEquals(Arrays.asList([1, 2]), authors); \ No newline at end of file diff --git a/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/simple-query.js b/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/simple-query.js deleted file mode 100644 index 69f665d13c..0000000000 --- a/jOOQ-examples/jOOQ-nashorn-example/src/test/java/org/jooq/example/test/simple-query.js +++ /dev/null @@ -1,16 +0,0 @@ -var DSL = Java.type("org.jooq.impl.DSL"); - -var Assert = Java.type("org.junit.Assert"); -var Arrays = Java.type("java.util.Arrays"); - -var Tables = Java.type("org.jooq.example.db.h2.Tables"); -var b = Tables.BOOK; -var a = Tables.AUTHOR; - -var books = DSL.using(connection) - .select(b.ID) - .from(b) - .orderBy(b.ID) - .fetch(b.ID); - -Assert.assertEquals(Arrays.asList([1, 2, 3, 4]), books); diff --git a/jOOQ-examples/jOOQ-oracle-example/src/test/java/org/jooq/example/QueriesWithTypes.java b/jOOQ-examples/jOOQ-oracle-example/src/test/java/org/jooq/example/QueriesWithTypes.java deleted file mode 100644 index 9f9fc9e617..0000000000 --- a/jOOQ-examples/jOOQ-oracle-example/src/test/java/org/jooq/example/QueriesWithTypes.java +++ /dev/null @@ -1,180 +0,0 @@ -/** - * Copyright (c) 2009-2013, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ -package org.jooq.example; - -import static java.util.stream.Collectors.toList; -import static java.util.stream.IntStream.range; -import static org.jooq.example.db.oracle.Queues.NEW_AUTHOR_AQ; -import static org.jooq.example.db.oracle.Tables.AUTHORS; -import static org.jooq.example.db.oracle.Tables.BOOKS; -import static org.jooq.impl.DSL.using; -// ... -// ... -import static org.junit.Assert.assertEquals; - -import java.util.List; - -import org.jooq.example.db.oracle.packages.Library; -import org.jooq.example.db.oracle.udt.records.AuthorTRecord; -import org.jooq.exception.DataAccessException; -import org.jooq.impl.DSL; -// ... -// ... -// ... -// ... - -import org.junit.Before; -import org.junit.Test; - -/** - * @author Lukas Eder - */ -public class QueriesWithTypes extends Utils { - - // Generate 10 authors - static final List authors = - range(0, 10).mapToObj(i -> new AuthorTRecord(i, "F" + i, "L1" + i, null)).collect(toList()); - - @Before - public void setup() { - dsl.transaction(ctx -> { - using(ctx).delete(BOOKS).execute(); - using(ctx).delete(AUTHORS).execute(); - - using(ctx).insertInto(AUTHORS, AUTHORS.ID, AUTHORS.FIRST_NAME, AUTHORS.LAST_NAME) - .values(1, "George", "Orwell") - .values(2, "Paulo" , "Coelho") - .execute(); - - using(ctx).insertInto(BOOKS, BOOKS.ID, BOOKS.TITLE, BOOKS.LANGUAGE, BOOKS.AUTHOR_ID) - .values(1, "1984" , "en", 1) - .values(2, "Animal Farm" , "en", 1) - .values(3, "O Alquimista", "pt", 2) - .values(4, "Brida" , "en", 2) - .execute(); - }); - } - - @Test - public void testProcedures() { - // TODO: Work on this nice table unnesting syntax, which currently doesn't work. - // dsl.selectFrom(table(Library.getAuthors(null, 1))) - // .fetch(); - - dsl.select(AUTHORS.FIRST_NAME, AUTHORS.LAST_NAME, Library.getBooks(AUTHORS.ID)) - .from(AUTHORS) - .fetch() - .forEach(author -> { - - System.out.println(); - System.out.println("Author " + author.getValue(AUTHORS.FIRST_NAME) + " " + author.getValue(AUTHORS.LAST_NAME) + " wrote: "); - author.value3().getList().forEach(book -> { - System.out.println(book.getTitle()); - }); - }); - } - - @Test - public void testAQSimple() throws Exception { - dsl.transaction(c -> { - - // Enqueue all authors - authors.stream().forEach(a -> { - DBMS_AQ.enqueue(dsl.configuration(), NEW_AUTHOR_AQ, a); - }); - - // Dequeue them again - authors.stream().forEach(a -> { - assertEquals(a, DBMS_AQ.dequeue(dsl.configuration(), NEW_AUTHOR_AQ)); - }); - }); - } - - @Test - public void testAQOptions() throws Exception { - dsl.transaction(c -> { - MESSAGE_PROPERTIES_T props = new MESSAGE_PROPERTIES_T(); - ENQUEUE_OPTIONS_T enq = new ENQUEUE_OPTIONS_T().visibility(IMMEDIATE); - - // Enqueue two authors - DBMS_AQ.enqueue(c, NEW_AUTHOR_AQ, authors.get(0), enq, props); - DBMS_AQ.enqueue(c, NEW_AUTHOR_AQ, authors.get(1), enq, props); - - // Dequeue them again - DEQUEUE_OPTIONS_T deq = new DEQUEUE_OPTIONS_T().wait(NO_WAIT); - - assertEquals(authors.get(0), DBMS_AQ.dequeue(c, NEW_AUTHOR_AQ, deq, props)); - assertEquals(authors.get(1), DBMS_AQ.dequeue(c, NEW_AUTHOR_AQ, deq, props)); - - // The queue is empty, this should fail - assertThrows(DataAccessException.class, () -> { - DBMS_AQ.dequeue(c, NEW_AUTHOR_AQ, deq, props); - }); - }); - } - - @Test - public void testAQTransactions() throws Exception { - dsl.transaction(c1 -> { - - // Enqueue an author - DBMS_AQ.enqueue(c1, NEW_AUTHOR_AQ, authors.get(0)); - - // This nested transaction is rolled back to its savepoint - assertThrows(RuntimeException.class, () -> { - DSL.using(c1).transaction(c2 -> { - DBMS_AQ.enqueue(c2, NEW_AUTHOR_AQ, authors.get(1)); - throw new RuntimeException(); - }); - }); - - // Dequeue the first author - MESSAGE_PROPERTIES_T props = new MESSAGE_PROPERTIES_T(); - DEQUEUE_OPTIONS_T deq = new DEQUEUE_OPTIONS_T().wait(NO_WAIT); - assertEquals(authors.get(0), DBMS_AQ.dequeue(c1, NEW_AUTHOR_AQ, deq, props)); - - // The queue is empty (due to the rollback), this should fail - assertThrows(DataAccessException.class, () -> { - DBMS_AQ.dequeue(c1, NEW_AUTHOR_AQ, deq, props); - }); - }); - } -} diff --git a/jOOQ-meta/src/main/java/org/jooq/util/postgres/pg_catalog/routines/PgCursor.java b/jOOQ-meta/src/main/java/org/jooq/util/postgres/pg_catalog/routines/PgCursor.java deleted file mode 100644 index 2fe74441cc..0000000000 --- a/jOOQ-meta/src/main/java/org/jooq/util/postgres/pg_catalog/routines/PgCursor.java +++ /dev/null @@ -1,101 +0,0 @@ -/** - * This class is generated by jOOQ - */ -package org.jooq.util.postgres.pg_catalog.routines; - -/** - * This class is generated by jOOQ. - */ -@javax.annotation.Generated(value = { "http://www.jooq.org", "3.4.0" }, - comments = "This class is generated by jOOQ") -@java.lang.SuppressWarnings({ "all", "unchecked", "rawtypes" }) -public class PgCursor extends org.jooq.impl.AbstractRoutine { - - private static final long serialVersionUID = 1657262595; - - /** - * The parameter pg_catalog.pg_cursor.name. - */ - public static final org.jooq.Parameter NAME = createParameter("name", org.jooq.impl.SQLDataType.CLOB); - - /** - * The parameter pg_catalog.pg_cursor.statement. - */ - public static final org.jooq.Parameter STATEMENT = createParameter("statement", org.jooq.impl.SQLDataType.CLOB); - - /** - * The parameter pg_catalog.pg_cursor.is_holdable. - */ - public static final org.jooq.Parameter IS_HOLDABLE = createParameter("is_holdable", org.jooq.impl.SQLDataType.BOOLEAN); - - /** - * The parameter pg_catalog.pg_cursor.is_binary. - */ - public static final org.jooq.Parameter IS_BINARY = createParameter("is_binary", org.jooq.impl.SQLDataType.BOOLEAN); - - /** - * The parameter pg_catalog.pg_cursor.is_scrollable. - */ - public static final org.jooq.Parameter IS_SCROLLABLE = createParameter("is_scrollable", org.jooq.impl.SQLDataType.BOOLEAN); - - /** - * The parameter pg_catalog.pg_cursor.creation_time. - */ - public static final org.jooq.Parameter CREATION_TIME = createParameter("creation_time", org.jooq.impl.SQLDataType.TIMESTAMP); - - /** - * Create a new routine call instance - */ - public PgCursor() { - super("pg_cursor", org.jooq.util.postgres.pg_catalog.PgCatalog.PG_CATALOG); - - addOutParameter(NAME); - addOutParameter(STATEMENT); - addOutParameter(IS_HOLDABLE); - addOutParameter(IS_BINARY); - addOutParameter(IS_SCROLLABLE); - addOutParameter(CREATION_TIME); - } - - /** - * Get the name parameter OUT value from the routine - */ - public java.lang.String getName_() { - return getValue(NAME); - } - - /** - * Get the statement parameter OUT value from the routine - */ - public java.lang.String getStatement() { - return getValue(STATEMENT); - } - - /** - * Get the is_holdable parameter OUT value from the routine - */ - public java.lang.Boolean getIsHoldable() { - return getValue(IS_HOLDABLE); - } - - /** - * Get the is_binary parameter OUT value from the routine - */ - public java.lang.Boolean getIsBinary() { - return getValue(IS_BINARY); - } - - /** - * Get the is_scrollable parameter OUT value from the routine - */ - public java.lang.Boolean getIsScrollable() { - return getValue(IS_SCROLLABLE); - } - - /** - * Get the creation_time parameter OUT value from the routine - */ - public java.sql.Timestamp getCreationTime() { - return getValue(CREATION_TIME); - } -} diff --git a/jOOQ-meta/src/main/resources/xjb/binding.xjb b/jOOQ-meta/src/main/resources/xjb/binding.xjb deleted file mode 100644 index 9517d40c4d..0000000000 --- a/jOOQ-meta/src/main/resources/xjb/binding.xjb +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/jOOQ-release/release/template/RELEASE-NOTES.txt.regex b/jOOQ-release/release/template/RELEASE-NOTES.txt.regex deleted file mode 100644 index b41905adc5..0000000000 --- a/jOOQ-release/release/template/RELEASE-NOTES.txt.regex +++ /dev/null @@ -1,16 +0,0 @@ -Sophisticated GitHub issue export script - -- "Export" from GitHub via copy paste -- Apply regexes: - o search ^\s*\d+$\n - replace - - o search ^#\d+.*?$\n - replace - - o search ^\s*(.*?) - Merge \[(.*?)\].*?$ - replace $2 - $1 - - -------------------------------------- - diff --git a/jOOQ/src/main/java/org/jooq/impl/AbstractSelect.java b/jOOQ/src/main/java/org/jooq/impl/AbstractSelect.java deleted file mode 100644 index cd10a9535a..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/AbstractSelect.java +++ /dev/null @@ -1,180 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ -package org.jooq.impl; - -import static org.jooq.impl.Utils.fieldArray; - -import java.sql.ResultSetMetaData; -import java.util.List; - -import org.jooq.Configuration; -import org.jooq.DataType; -import org.jooq.Field; -import org.jooq.Record; -import org.jooq.Result; -import org.jooq.Row; -import org.jooq.Select; -import org.jooq.Table; -import org.jooq.exception.DataAccessException; - -/** - * A common base class for all SELECT statements. - * - * @author Lukas Eder - */ -abstract class AbstractSelect extends AbstractResultQuery implements Select { - - private static final long serialVersionUID = 5432006637149005588L; - - AbstractSelect(Configuration configuration) { - super(configuration); - } - - @Override - public final int fetchCount() throws DataAccessException { - return DSL.using(configuration()).fetchCount(this); - } - - @Override - public final Select union(Select select) { - return new Union(configuration(), this, select, CombineOperator.UNION); - } - - @Override - public final Select unionAll(Select select) { - return new Union(configuration(), this, select, CombineOperator.UNION_ALL); - } - - @Override - public final Select except(Select select) { - return new Union(configuration(), this, select, CombineOperator.EXCEPT); - } - - @Override - public final Select intersect(Select select) { - return new Union(configuration(), this, select, CombineOperator.INTERSECT); - } - - @SuppressWarnings("unchecked") - @Override - public final Field asField() { - if (getSelect().size() != 1) { - throw new IllegalStateException("Can only use single-column ResultProviderQuery as a field"); - } - - return new SelectQueryAsField(this, (DataType) getSelect().get(0).getDataType()); - } - - @Override - public final Field asField(String alias) { - return this. asField().as(alias); - } - - @Override - public final Row fieldsRow() { - return asTable().fieldsRow(); - } - - @Override - public final Field field(Field field) { - return asTable().field(field); - } - - @Override - public final Field field(String string) { - return asTable().field(string); - } - - @Override - public final Field field(int index) { - return asTable().field(index); - } - - @Override - public final Field[] fields() { - return asTable().fields(); - } - - @Override - public final Table asTable() { - // Its usually better to alias nested selects that are used in - // the FROM clause of a query - return new SelectQueryAsTable(this).as("alias_" + Utils.hash(this)); - } - - @Override - public final Table asTable(String alias) { - return new SelectQueryAsTable(this).as(alias); - } - - @Override - public final Table asTable(String alias, String... fieldAliases) { - return new SelectQueryAsTable(this).as(alias, fieldAliases); - } - - @Override - protected final Field[] getFields(ResultSetMetaData meta) { - - // [#1808] TODO: Restrict this field list, in case a restricting fetch() - // method was called to get here - List> fields = getSelect(); - - // If no projection was specified explicitly, create fields from result - // set meta data instead. This is typically the case for SELECT * ... - if (fields.isEmpty()) { - Configuration configuration = configuration(); - return new MetaDataFieldProvider(configuration, meta).getFields(); - } - - return fieldArray(fields); - } - - @Override - final boolean isSelectingRefCursor() { - for (Field field : getSelect()) { - if (Result.class.isAssignableFrom(field.getType())) { - return true; - } - } - - return false; - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/DefaultArray.java b/jOOQ/src/main/java/org/jooq/impl/DefaultArray.java deleted file mode 100644 index 57a57ab505..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/DefaultArray.java +++ /dev/null @@ -1,115 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ -package org.jooq.impl; - -import java.sql.Array; -import java.sql.ResultSet; -import java.util.Map; - -import org.jooq.SQLDialect; -import org.jooq.exception.SQLDialectNotSupportedException; - -class DefaultArray implements Array { - - private final SQLDialect dialect; - private final Object[] array; - private final Class type; - - public DefaultArray(SQLDialect dialect, Object[] array, Class type) { - this.dialect = dialect; - this.array = array; - this.type = type; - } - - @Override - public String getBaseTypeName() { - return DefaultDataType.getDataType(dialect, type.getComponentType()).getTypeName(); - } - - @Override - public int getBaseType() { - throw new SQLDialectNotSupportedException("Array.getBaseType()"); - } - - @Override - public Object getArray() { - return array; - } - - @Override - public Object getArray(Map> map) { - return array; - } - - @Override - public Object getArray(long index, int count) { - throw new SQLDialectNotSupportedException("Array.getArray(long, int)"); - } - - @Override - public Object getArray(long index, int count, Map> map) { - throw new SQLDialectNotSupportedException("Array.getArray(long, int, Map)"); - } - - @Override - public ResultSet getResultSet() { - throw new SQLDialectNotSupportedException("Array.getResultSet()"); - } - - @Override - public ResultSet getResultSet(Map> map) { - throw new SQLDialectNotSupportedException("Array.getResultSet(Map)"); - } - - @Override - public ResultSet getResultSet(long index, int count) { - throw new SQLDialectNotSupportedException("Array.getResultSet(long, int)"); - } - - @Override - public ResultSet getResultSet(long index, int count, Map> map) { - throw new SQLDialectNotSupportedException("Array.getResultSet(long, int, Map)"); - } - - @Override - public void free() { - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/ExistsOperator.java b/jOOQ/src/main/java/org/jooq/impl/ExistsOperator.java deleted file mode 100644 index 027098ed26..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/ExistsOperator.java +++ /dev/null @@ -1,63 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ - -package org.jooq.impl; - -/** - * An operator for the {@link ExistsCondition} - * - * @author Lukas Eder - */ -enum ExistsOperator { - - EXISTS("exists"), - NOT_EXISTS("not exists"); - - private final String sql; - - private ExistsOperator(String sql) { - this.sql = sql; - } - - public String toSQL() { - return sql; - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/SQLTemplate.java b/jOOQ/src/main/java/org/jooq/impl/SQLTemplate.java deleted file mode 100644 index 2a1435d5bc..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/SQLTemplate.java +++ /dev/null @@ -1,96 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ -package org.jooq.impl; - -import static org.jooq.Clause.TEMPLATE; - -import java.util.List; - -import org.jooq.Clause; -import org.jooq.Context; -import org.jooq.QueryPart; -import org.jooq.Template; - -@SuppressWarnings("deprecation") -class SQLTemplate implements Template { - - private final String sql; - - SQLTemplate(String sql) { - this.sql = sql; - } - - @Override - public final QueryPart transform(Object... input) { - return new SQLTemplateQueryPart(sql, input); - } - - private static class SQLTemplateQueryPart extends AbstractQueryPart { - - /** - * Generated UID - */ - private static final long serialVersionUID = -7514156096865122018L; - private static final Clause[] CLAUSES = { TEMPLATE }; - private final String sql; - private final List substitutes; - - SQLTemplateQueryPart(String sql, Object... input) { - this.sql = sql; - this.substitutes = Utils.queryParts(input); - } - - @Override - public final void accept(Context ctx) { - Utils.renderAndBind(ctx, sql, substitutes); - } - - @Override - public final Clause[] clauses(Context ctx) { - return CLAUSES; - } - - @Override - public String toString() { - return sql; - } - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsExistsCondition.java b/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsExistsCondition.java deleted file mode 100644 index de27fc3259..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsExistsCondition.java +++ /dev/null @@ -1,102 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ - -package org.jooq.impl; - -import static org.jooq.Clause.CONDITION; -import static org.jooq.Clause.CONDITION_EXISTS; -import static org.jooq.Clause.CONDITION_NOT_EXISTS; -import static org.jooq.impl.ExistsOperator.EXISTS; - -import org.jooq.Clause; -import org.jooq.Context; -import org.jooq.Select; - -/** - * @author Lukas Eder - */ -class SelectQueryAsExistsCondition extends AbstractCondition { - - private static final long serialVersionUID = 5678338161136603292L; - private static final Clause[] CLAUSES_EXISTS = { CONDITION, CONDITION_EXISTS }; - private static final Clause[] CLAUSES_EXISTS_NOT = { CONDITION, CONDITION_NOT_EXISTS }; - - private final Select query; - private final ExistsOperator operator; - - SelectQueryAsExistsCondition(Select query, ExistsOperator operator) { - this.query = query; - this.operator = operator; - } - - @Override - public final void accept(Context ctx) { - - // If this is already a subquery, proceed - if (ctx.subquery()) { - ctx.keyword(operator.toSQL()) - .sql(" (") - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .sql(")"); - } - else { - ctx.keyword(operator.toSQL()) - .sql(" (") - .subquery(true) - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .subquery(false) - .sql(")"); - } - } - - @Override - public final Clause[] clauses(Context ctx) { - return operator == EXISTS ? CLAUSES_EXISTS : CLAUSES_EXISTS_NOT; - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsField.java b/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsField.java deleted file mode 100644 index 01b1633dfa..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsField.java +++ /dev/null @@ -1,94 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ - -package org.jooq.impl; - -import org.jooq.Context; -import org.jooq.DataType; -import org.jooq.Field; -import org.jooq.Select; - -/** - * @author Lukas Eder - */ -class SelectQueryAsField extends AbstractField { - - private static final long serialVersionUID = 3463144434073231750L; - - private final Select query; - - SelectQueryAsField(Select query, DataType type) { - super("select", type); - - this.query = query; - } - - @Override - public final Field as(String alias) { - return new FieldAlias(this, alias); - } - - @Override - public final void accept(Context ctx) { - - // If this is already a subquery, proceed - if (ctx.subquery()) { - ctx.sql("(") - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .sql(")"); - } - else { - ctx.sql("(") - .subquery(true) - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .subquery(false) - .sql(")"); - } - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsSubQueryCondition.java b/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsSubQueryCondition.java deleted file mode 100644 index d938b68e2f..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsSubQueryCondition.java +++ /dev/null @@ -1,107 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ - -package org.jooq.impl; - -import static org.jooq.Clause.CONDITION; -import static org.jooq.Clause.CONDITION_COMPARISON; - -import org.jooq.Clause; -import org.jooq.Comparator; -import org.jooq.Context; -import org.jooq.Field; -import org.jooq.Select; - -/** - * @author Lukas Eder - */ -class SelectQueryAsSubQueryCondition extends AbstractCondition { - - private static final long serialVersionUID = -402776705884329740L; - private static final Clause[] CLAUSES = { CONDITION, CONDITION_COMPARISON }; - - private final Select query; - private final Field field; - private final Comparator comparator; - - SelectQueryAsSubQueryCondition(Select query, Field field, Comparator comparator) { - this.query = query; - this.field = field; - this.comparator = comparator; - } - - @Override - public final void accept(Context ctx) { - - // If this is already a subquery, proceed - if (ctx.subquery()) { - ctx.visit(field) - .sql(" ") - .keyword(comparator.toSQL()) - .sql(" (") - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .sql(")"); - } - else { - ctx.visit(field) - .sql(" ") - .keyword(comparator.toSQL()) - .sql(" (") - .subquery(true) - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .subquery(false) - .sql(")"); - } - } - - @Override - public final Clause[] clauses(Context ctx) { - return CLAUSES; - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsTable.java b/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsTable.java deleted file mode 100644 index 54b4c13440..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/SelectQueryAsTable.java +++ /dev/null @@ -1,115 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ - -package org.jooq.impl; - -import org.jooq.Clause; -import org.jooq.Context; -import org.jooq.Record; -import org.jooq.Select; -import org.jooq.Table; - -/** - * @author Lukas Eder - */ -class SelectQueryAsTable extends AbstractTable { - - private static final long serialVersionUID = 6272398035926615668L; - - private final Select query; - - SelectQueryAsTable(Select query) { - super("select"); - - this.query = query; - } - - final Select query() { - return query; - } - - @Override - public final Table as(String alias) { - return new TableAlias(this, alias, true); - } - - @Override - public final Table as(String alias, String... fieldAliases) { - return new TableAlias(this, alias, fieldAliases, true); - } - - @Override - final Fields fields0() { - return new Fields(query.getSelect()); - } - - @Override - public final Class getRecordType() { - return query.getRecordType(); - } - - @Override - public final void accept(Context ctx) { - - // If this is already a subquery, proceed - if (ctx.subquery()) { - ctx.formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine(); - } - else { - ctx.subquery(true) - .formatIndentStart() - .formatNewLine() - .visit(query) - .formatIndentEnd() - .formatNewLine() - .subquery(false); - } - } - - @Override - public final Clause[] clauses(Context ctx) { - return null; - } -} diff --git a/jOOQ/src/main/java/org/jooq/impl/Union.java b/jOOQ/src/main/java/org/jooq/impl/Union.java deleted file mode 100644 index a29e687b1f..0000000000 --- a/jOOQ/src/main/java/org/jooq/impl/Union.java +++ /dev/null @@ -1,155 +0,0 @@ -/** - * Copyright (c) 2009-2014, Data Geekery GmbH (http://www.datageekery.com) - * All rights reserved. - * - * This work is dual-licensed - * - under the Apache Software License 2.0 (the "ASL") - * - under the jOOQ License and Maintenance Agreement (the "jOOQ License") - * ============================================================================= - * You may choose which license applies to you: - * - * - If you're using this work with Open Source databases, you may choose - * either ASL or jOOQ License. - * - If you're using this work with at least one commercial database, you must - * choose jOOQ License - * - * For more information, please visit http://www.jooq.org/licenses - * - * Apache Software License 2.0: - * ----------------------------------------------------------------------------- - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * jOOQ License and Maintenance Agreement: - * ----------------------------------------------------------------------------- - * Data Geekery grants the Customer the non-exclusive, timely limited and - * non-transferable license to install and use the Software under the terms of - * the jOOQ License and Maintenance Agreement. - * - * This library is distributed with a LIMITED WARRANTY. See the jOOQ License - * and Maintenance Agreement for more details: http://www.jooq.org/licensing - */ -package org.jooq.impl; - -import static org.jooq.Clause.SELECT_EXCEPT; -import static org.jooq.Clause.SELECT_INTERSECT; -import static org.jooq.Clause.SELECT_UNION; -import static org.jooq.Clause.SELECT_UNION_ALL; - -import java.util.ArrayList; -import java.util.List; - -import org.jooq.Clause; -import org.jooq.Configuration; -import org.jooq.Context; -import org.jooq.Field; -import org.jooq.Record; -import org.jooq.Select; - -/** - * A union is a SELECT statement that combines several sub-selects - * with a UNION or a similar operator. - * - * @author Lukas Eder - */ -class Union extends AbstractSelect { - - private static final long serialVersionUID = 7491446471677986172L; - - private final List> queries; - private final CombineOperator operator; - private final Clause[] clauses; - - Union(Configuration configuration, Select query1, Select query2, CombineOperator operator) { - super(configuration); - - this.queries = new ArrayList>(); - this.queries.add(query1); - this.queries.add(query2); - this.operator = operator; - - switch (operator) { - case EXCEPT: this.clauses = new Clause[] { SELECT_EXCEPT } ; break; - case INTERSECT: this.clauses = new Clause[] { SELECT_INTERSECT } ; break; - case UNION: this.clauses = new Clause[] { SELECT_UNION } ; break; - case UNION_ALL: this.clauses = new Clause[] { SELECT_UNION_ALL } ; break; - default: throw new IllegalArgumentException("Operator not supported : " + operator); - } - } - - @Override - public final Class getRecordType() { - return queries.get(0).getRecordType(); - } - - @Override - public final List> getSelect() { - return queries.get(0).getSelect(); - } - - @Override - public final void accept(Context ctx) { - for (int i = 0; i < queries.size(); i++) { - if (i != 0) { - ctx.formatSeparator() - .keyword(operator.toSQL(ctx.configuration().dialect())) - .formatSeparator(); - } - - wrappingParenthesis(ctx, "("); - ctx.visit(queries.get(i)); - wrappingParenthesis(ctx, ")"); - } - } - - private final void wrappingParenthesis(Context ctx, String parenthesis) { - switch (ctx.configuration().dialect()) { - // Sybase ASE, Derby, Firebird and SQLite have some syntax issues with unions. - // Check out https://issues.apache.org/jira/browse/DERBY-2374 - /* [pro] xx - xxxx xxxxxxx - xxxx xxxx - xx [/pro] */ - case DERBY: - case FIREBIRD: - case SQLITE: - - // [#288] MySQL has a very special way of dealing with UNION's - // So include it as well - case MARIADB: - case MYSQL: - return; - } - - if (")".equals(parenthesis)) { - ctx.formatIndentEnd() - .formatNewLine(); - } - - ctx.sql(parenthesis); - - if ("(".equals(parenthesis)) { - ctx.formatIndentStart() - .formatNewLine(); - } - } - - @Override - public final Clause[] clauses(Context ctx) { - return clauses; - } - - @Override - final boolean isForUpdate() { - return false; - } -} diff --git a/jOOQ/src/main/resources/xsd/jooq-pro.xsd b/jOOQ/src/main/resources/xsd/jooq-pro.xsd deleted file mode 100644 index b35d90276c..0000000000 --- a/jOOQ/src/main/resources/xsd/jooq-pro.xsd +++ /dev/null @@ -1,12 +0,0 @@ - - - - - \ No newline at end of file