diff options
author | Ralf Mollik | 2017-08-28 15:42:56 +0000 |
---|---|---|
committer | Ralf Mollik | 2017-08-28 15:42:56 +0000 |
commit | 5e1560a260645448c39567fbf159852b4ddabeb8 (patch) | |
tree | 62846ee27014380211041316b4870268aa9393e6 | |
download | org.eclipse.osbp.xtext.table.common-5e1560a260645448c39567fbf159852b4ddabeb8.tar.gz org.eclipse.osbp.xtext.table.common-5e1560a260645448c39567fbf159852b4ddabeb8.tar.xz org.eclipse.osbp.xtext.table.common-5e1560a260645448c39567fbf159852b4ddabeb8.zip |
parallel ip - initial checkin
Signed-off-by: Ralf Mollik <ramollik@compex-commerce.com>
39 files changed, 4497 insertions, 0 deletions
diff --git a/.project b/.project new file mode 100644 index 0000000..8a8de78 --- /dev/null +++ b/.project @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.osbp.xtext.table.common.aggregator</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.m2e.core.maven2Builder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.sonarlint.eclipse.core.sonarlintBuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.m2e.core.maven2Nature</nature> + </natures> +</projectDescription> diff --git a/about.html b/about.html new file mode 100644 index 0000000..64c0598 --- /dev/null +++ b/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 1, 2016</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise +indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html>
\ No newline at end of file diff --git a/jenkins.build.config.xml b/jenkins.build.config.xml new file mode 100644 index 0000000..5f6f60a --- /dev/null +++ b/jenkins.build.config.xml @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--#======================================================================= --> +<!--# Copyright (c) 2016 - Loetz GmbH&Co.KG --> +<!--# All rights reserved. This program and the accompanying materials --> +<!--# are made available under the terms of the Eclipse Public License v1.0 --> +<!--# which accompanies this distribution, and is available at --> +<!--# http://www.eclipse.org/legal/epl-v10.html --> +<!--# --> +<!--# Contributors: --> +<!--# Christophe Loetz (Loetz GmbH&Co.KG) - initial API and implementation --> +<!--#======================================================================= --> +<!--# Module specific parameters for the Jenkins Job --> +<!--#======================================================================= --> + +<jenkins> + <!-- DO NOT EDIT BELOW THIS LINE --> + <jenkins.build.dependencies> + <jenkins.build.dependency>org.eclipse.osbp.runtime</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.runtime.web</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.ui.api</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.utils</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.utils.blob</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.utils.themes.ui</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.utils.ui</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.xtext.datamart.common</jenkins.build.dependency> + <jenkins.build.dependency>org.eclipse.osbp.xtext.i18n</jenkins.build.dependency> + </jenkins.build.dependencies> +</jenkins> diff --git a/notice.html b/notice.html new file mode 100644 index 0000000..c3d34c3 --- /dev/null +++ b/notice.html @@ -0,0 +1,107 @@ +<?xml version="1.0" encoding="ISO-8859-1" ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> +<title>Eclipse Foundation Software User Agreement</title> +</head> + +<body lang="EN-US"> +<h2>Eclipse Foundation Software User Agreement</h2> +<p>April 9, 2014</p> + +<h3>Usage Of Content</h3> + +<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS + (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND + CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE + OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR + NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND + CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p> + +<h3>Applicable Licenses</h3> + +<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 + ("EPL"). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. + For purposes of the EPL, "Program" will mean the Content.</p> + +<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code + repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").</p> + +<ul> + <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").</li> + <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li> + <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins + and/or Fragments associated with that Feature.</li> + <li>Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.</li> +</ul> + +<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and +Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module +including, but not limited to the following locations:</p> + +<ul> + <li>The top-level (root) directory</li> + <li>Plug-in and Fragment directories</li> + <li>Inside Plug-ins and Fragments packaged as JARs</li> + <li>Sub-directories of the directory named "src" of certain Plug-ins</li> + <li>Feature directories</li> +</ul> + +<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the +installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or +inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. +Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in +that directory.</p> + +<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE +OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p> + +<ul> + <li>Eclipse Distribution License Version 1.0 (available at <a href="http://www.eclipse.org/licenses/edl-v10.html">http://www.eclipse.org/licenses/edl-v1.0.html</a>)</li> + <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li> + <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li> + <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li> + <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li> +</ul> + +<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please +contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p> + + +<h3>Use of Provisioning Technology</h3> + +<p>The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse + Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or + other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to + install, extend and update Eclipse-based products. Information about packaging Installable Software is available at <a + href="http://eclipse.org/equinox/p2/repository_packaging.html">http://eclipse.org/equinox/p2/repository_packaging.html</a> + ("Specification").</p> + +<p>You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the + applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology + in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the + Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:</p> + +<ol> + <li>A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology + on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based + product.</li> + <li>During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be + accessed and copied to the Target Machine.</li> + <li>Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable + Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target + Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern + the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such + indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.</li> +</ol> + +<h3>Cryptography</h3> + +<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to + another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, + possession, or use, and re-export of encryption software, to see if this is permitted.</p> + +<p><small>Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.</small></p> +</body> +</html> diff --git a/org.eclipse.osbp.xtext.table.common.feature/.project b/org.eclipse.osbp.xtext.table.common.feature/.project new file mode 100644 index 0000000..9f80629 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/.project @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.osbp.xtext.table.common.feature</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.xtext.ui.shared.xtextBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.FeatureBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.m2e.core.maven2Builder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.sonarlint.eclipse.core.sonarlintBuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.xtext.ui.shared.xtextNature</nature> + <nature>org.eclipse.m2e.core.maven2Nature</nature> + <nature>org.eclipse.pde.FeatureNature</nature> + </natures> +</projectDescription> diff --git a/org.eclipse.osbp.xtext.table.common.feature/LICENSE.txt b/org.eclipse.osbp.xtext.table.common.feature/LICENSE.txt new file mode 100644 index 0000000..ff42ad4 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/LICENSE.txt @@ -0,0 +1,161 @@ +Eclipse Public License -v 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION +OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + +a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and + +b) in the case of each subsequent Contributor: + +i) changes to the Program, and + +ii) additions to the Program; + +where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. +A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone +acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate +modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not +derivative works of the Program. + +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of +its Contribution alone or when combined with the Program. + +"Program" means the Contributions distributed in accordance with this Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. + +2. GRANT OF RIGHTS + +a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute +and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code +form. + +b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the +Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the +combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such +addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not +apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. + +c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no +assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property +rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity +based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and +licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property +rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the +Program, it is Recipient's responsibility to acquire that license before distributing the Program. + +d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to +grant the copyright license set forth in this Agreement. + +3. REQUIREMENTS + +A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: + +a) it complies with the terms and conditions of this Agreement; and + +b) its license agreement: + +i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including +warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and +fitness for a particular purpose; + +ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, +incidental and consequential damages, such as lost profits; + +iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any +other party; and + +iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it +in a reasonable manner on or through a medium customarily used for software exchange. + +When the Program is made available in source code form: + +a) it must be made available under this Agreement; and + +b) a copy of this Agreement must be included with each copy of the Program. + +Contributors may not remove or alter any copyright notices contained within the Program. + +Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows +subsequent Recipients to identify the originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and +the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes +the Program in a commercial product offering should do so in a manner which does not create potential liability for +other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor +("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") +against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions +brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such +Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The +obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual +property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial +Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the +Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may + participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is +then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties +related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. +Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to +those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, +the Commercial Contributor must pay those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR +CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, +NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for +determining the appropriateness of using and distributing the Program and assumes all risks associated with its +exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance +with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), +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 OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED +HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or +enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such +provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) +alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such +Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such +litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or +conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such +noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution +of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses + granted by Recipient relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement +is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish +new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the +right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may +assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the +Agreement will be given a distinguishing version number. The Program (including Contributions) may always be +distributed subject to the version of the Agreement under which it was received. In addition, after a new version of +the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the +new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to +the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or +otherwise. All rights in the Program not expressly granted under this Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States +of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause +of action arose. Each party waives its rights to a jury trial in any resulting litigation.
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common.feature/build.properties b/org.eclipse.osbp.xtext.table.common.feature/build.properties new file mode 100644 index 0000000..b8920ff --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/build.properties @@ -0,0 +1,2 @@ +bin.includes = license.html, epl-v10.html, feature.xml,\ + feature.properties diff --git a/org.eclipse.osbp.xtext.table.common.feature/epl-v10.html b/org.eclipse.osbp.xtext.table.common.feature/epl-v10.html new file mode 100644 index 0000000..b398acc --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/epl-v10.html @@ -0,0 +1,259 @@ +<!--?xml version="1.0" encoding="ISO-8859-1" ?--> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> +<title>Eclipse Public License - Version 1.0</title> +<style type="text/css"> + body { + size: 8.5in 11.0in; + margin: 0.25in 0.5in 0.25in 0.5in; + tab-interval: 0.5in; + } + p { + margin-left: auto; + margin-top: 0.5em; + margin-bottom: 0.5em; + } + p.list { + margin-left: 0.5in; + margin-top: 0.05em; + margin-bottom: 0.05em; + } + </style> + +</head> + +<body lang="EN-US"> + +<h2>Eclipse Public License - v 1.0</h2> + +<p>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE +PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR +DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS +AGREEMENT.</p> + +<p><b>1. DEFINITIONS</b></p> + +<p>"Contribution" means:</p> + +<p class="list">a) in the case of the initial Contributor, the initial +code and documentation distributed under this Agreement, and</p> +<p class="list">b) in the case of each subsequent Contributor:</p> +<p class="list">i) changes to the Program, and</p> +<p class="list">ii) additions to the Program;</p> +<p class="list">where such changes and/or additions to the Program +originate from and are distributed by that particular Contributor. A +Contribution 'originates' from a Contributor if it was added to the +Program by such Contributor itself or anyone acting on such +Contributor's behalf. Contributions do not include additions to the +Program which: (i) are separate modules of software distributed in +conjunction with the Program under their own license agreement, and (ii) +are not derivative works of the Program.</p> + +<p>"Contributor" means any person or entity that distributes +the Program.</p> + +<p>"Licensed Patents" mean patent claims licensable by a +Contributor which are necessarily infringed by the use or sale of its +Contribution alone or when combined with the Program.</p> + +<p>"Program" means the Contributions distributed in accordance +with this Agreement.</p> + +<p>"Recipient" means anyone who receives the Program under +this Agreement, including all Contributors.</p> + +<p><b>2. GRANT OF RIGHTS</b></p> + +<p class="list">a) Subject to the terms of this Agreement, each +Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free copyright license to reproduce, prepare derivative works +of, publicly display, publicly perform, distribute and sublicense the +Contribution of such Contributor, if any, and such derivative works, in +source code and object code form.</p> + +<p class="list">b) Subject to the terms of this Agreement, each +Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free patent license under Licensed Patents to make, use, sell, +offer to sell, import and otherwise transfer the Contribution of such +Contributor, if any, in source code and object code form. This patent +license shall apply to the combination of the Contribution and the +Program if, at the time the Contribution is added by the Contributor, +such addition of the Contribution causes such combination to be covered +by the Licensed Patents. The patent license shall not apply to any other +combinations which include the Contribution. No hardware per se is +licensed hereunder.</p> + +<p class="list">c) Recipient understands that although each Contributor +grants the licenses to its Contributions set forth herein, no assurances +are provided by any Contributor that the Program does not infringe the +patent or other intellectual property rights of any other entity. Each +Contributor disclaims any liability to Recipient for claims brought by +any other entity based on infringement of intellectual property rights +or otherwise. As a condition to exercising the rights and licenses +granted hereunder, each Recipient hereby assumes sole responsibility to +secure any other intellectual property rights needed, if any. For +example, if a third party patent license is required to allow Recipient +to distribute the Program, it is Recipient's responsibility to acquire +that license before distributing the Program.</p> + +<p class="list">d) Each Contributor represents that to its knowledge it +has sufficient copyright rights in its Contribution, if any, to grant +the copyright license set forth in this Agreement.</p> + +<p><b>3. REQUIREMENTS</b></p> + +<p>A Contributor may choose to distribute the Program in object code +form under its own license agreement, provided that:</p> + +<p class="list">a) it complies with the terms and conditions of this +Agreement; and</p> + +<p class="list">b) its license agreement:</p> + +<p class="list">i) effectively disclaims on behalf of all Contributors +all warranties and conditions, express and implied, including warranties +or conditions of title and non-infringement, and implied warranties or +conditions of merchantability and fitness for a particular purpose;</p> + +<p class="list">ii) effectively excludes on behalf of all Contributors +all liability for damages, including direct, indirect, special, +incidental and consequential damages, such as lost profits;</p> + +<p class="list">iii) states that any provisions which differ from this +Agreement are offered by that Contributor alone and not by any other +party; and</p> + +<p class="list">iv) states that source code for the Program is available +from such Contributor, and informs licensees how to obtain it in a +reasonable manner on or through a medium customarily used for software +exchange.</p> + +<p>When the Program is made available in source code form:</p> + +<p class="list">a) it must be made available under this Agreement; and</p> + +<p class="list">b) a copy of this Agreement must be included with each +copy of the Program.</p> + +<p>Contributors may not remove or alter any copyright notices contained +within the Program.</p> + +<p>Each Contributor must identify itself as the originator of its +Contribution, if any, in a manner that reasonably allows subsequent +Recipients to identify the originator of the Contribution.</p> + +<p><b>4. COMMERCIAL DISTRIBUTION</b></p> + +<p>Commercial distributors of software may accept certain +responsibilities with respect to end users, business partners and the +like. While this license is intended to facilitate the commercial use of +the Program, the Contributor who includes the Program in a commercial +product offering should do so in a manner which does not create +potential liability for other Contributors. Therefore, if a Contributor +includes the Program in a commercial product offering, such Contributor +("Commercial Contributor") hereby agrees to defend and +indemnify every other Contributor ("Indemnified Contributor") +against any losses, damages and costs (collectively "Losses") +arising from claims, lawsuits and other legal actions brought by a third +party against the Indemnified Contributor to the extent caused by the +acts or omissions of such Commercial Contributor in connection with its +distribution of the Program in a commercial product offering. The +obligations in this section do not apply to any claims or Losses +relating to any actual or alleged intellectual property infringement. In +order to qualify, an Indemnified Contributor must: a) promptly notify +the Commercial Contributor in writing of such claim, and b) allow the +Commercial Contributor to control, and cooperate with the Commercial +Contributor in, the defense and any related settlement negotiations. The +Indemnified Contributor may participate in any such claim at its own +expense.</p> + +<p>For example, a Contributor might include the Program in a commercial +product offering, Product X. That Contributor is then a Commercial +Contributor. If that Commercial Contributor then makes performance +claims, or offers warranties related to Product X, those performance +claims and warranties are such Commercial Contributor's responsibility +alone. Under this section, the Commercial Contributor would have to +defend claims against the other Contributors related to those +performance claims and warranties, and if a court requires any other +Contributor to pay any damages as a result, the Commercial Contributor +must pay those damages.</p> + +<p><b>5. NO WARRANTY</b></p> + +<p>EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS +PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS +OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, +ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY +OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely +responsible for determining the appropriateness of using and +distributing the Program and assumes all risks associated with its +exercise of rights under this Agreement , including but not limited to +the risks and costs of program errors, compliance with applicable laws, +damage to or loss of data, programs or equipment, and unavailability or +interruption of operations.</p> + +<p><b>6. DISCLAIMER OF LIABILITY</b></p> + +<p>EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT +NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING +WITHOUT LIMITATION LOST PROFITS), 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 OR +DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED +HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</p> + +<p><b>7. GENERAL</b></p> + +<p>If any provision of this Agreement is invalid or unenforceable under +applicable law, it shall not affect the validity or enforceability of +the remainder of the terms of this Agreement, and without further action +by the parties hereto, such provision shall be reformed to the minimum +extent necessary to make such provision valid and enforceable.</p> + +<p>If Recipient institutes patent litigation against any entity +(including a cross-claim or counterclaim in a lawsuit) alleging that the +Program itself (excluding combinations of the Program with other +software or hardware) infringes such Recipient's patent(s), then such +Recipient's rights granted under Section 2(b) shall terminate as of the +date such litigation is filed.</p> + +<p>All Recipient's rights under this Agreement shall terminate if it +fails to comply with any of the material terms or conditions of this +Agreement and does not cure such failure in a reasonable period of time +after becoming aware of such noncompliance. If all Recipient's rights +under this Agreement terminate, Recipient agrees to cease use and +distribution of the Program as soon as reasonably practicable. However, +Recipient's obligations under this Agreement and any licenses granted by +Recipient relating to the Program shall continue and survive.</p> + +<p>Everyone is permitted to copy and distribute copies of this +Agreement, but in order to avoid inconsistency the Agreement is +copyrighted and may only be modified in the following manner. The +Agreement Steward reserves the right to publish new versions (including +revisions) of this Agreement from time to time. No one other than the +Agreement Steward has the right to modify this Agreement. The Eclipse +Foundation is the initial Agreement Steward. The Eclipse Foundation may +assign the responsibility to serve as the Agreement Steward to a +suitable separate entity. Each new version of the Agreement will be +given a distinguishing version number. The Program (including +Contributions) may always be distributed subject to the version of the +Agreement under which it was received. In addition, after a new version +of the Agreement is published, Contributor may elect to distribute the +Program (including its Contributions) under the new version. Except as +expressly stated in Sections 2(a) and 2(b) above, Recipient receives no +rights or licenses to the intellectual property of any Contributor under +this Agreement, whether expressly, by implication, estoppel or +otherwise. All rights in the Program not expressly granted under this +Agreement are reserved.</p> + +<p>This Agreement is governed by the laws of the State of New York and +the intellectual property laws of the United States of America. No party +to this Agreement will bring a legal action under this Agreement more +than one year after the cause of action arose. Each party waives its +rights to a jury trial in any resulting litigation.</p> + + + +</body></html>
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common.feature/feature.properties b/org.eclipse.osbp.xtext.table.common.feature/feature.properties new file mode 100644 index 0000000..2a6096c --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/feature.properties @@ -0,0 +1,169 @@ +############################################################################### +# Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany). +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# Cristiano Gavião - initial API and implementation +############################################################################### +# feature.properties +# contains externalized strings for feature.xml +# "%foo" in feature.xml corresponds to the key "foo" in this file +# java.io.Properties file (ISO 8859-1 with "\" escapes) +# This file should be translated. + +# "featureName" property - name of the feature +featureName =OSBP DSL: Table common + +# "providerName" property - name of the company that provides the feature +providerName=Eclipse OSBP + +# "description" property - description of the feature +description=This feature provides the common bundles for the OSBP table DSL. + +# "updateSiteName" property - label for the update site +updateSiteName= + +# "copyright" property - text of the "Feature Update Copyright" +copyright=\ +Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) \n\ +All rights reserved. This program and the accompanying materials\n\ +are made available under the terms of the Eclipse Public License v1.0\n\ +which accompanies this distribution, and is available at\n\ +http://www.eclipse.org/legal/epl-v10.html\n\ +\n\ +################ end of copyright property #################################### + +# "licenseURL" property - URL of the "Feature License" +# do not translate value - just change to point to a locale-specific HTML page +licenseURL=license.html + +# "license" property - text of the "Feature Update License" +# should be plain text version of license agreement pointed to be "licenseURL" +license=\ +Eclipse Foundation Software User Agreement\n\ +February 1, 2011\n\ +\n\ +Usage Of Content\n\ +\n\ +THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\n\ +OTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\n\ +USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\n\ +AGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\n\ +NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\n\ +AGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\n\ +AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\n\ +OR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\n\ +TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\n\ +OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\n\ +BELOW, THEN YOU MAY NOT USE THE CONTENT.\n\ +\n\ +Applicable Licenses\n\ +\n\ +Unless otherwise indicated, all Content made available by the\n\ +Eclipse Foundation is provided to you under the terms and conditions of\n\ +the Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is\n\ +provided with this Content and is also available at http://www.eclipse.org/legal/epl-v10.html.\n\ +For purposes of the EPL, "Program" will mean the Content.\n\ +\n\ +Content includes, but is not limited to, source code, object code,\n\ +documentation and other files maintained in the Eclipse Foundation source code\n\ +repository ("Repository") in software modules ("Modules") and made available\n\ +as downloadable archives ("Downloads").\n\ +\n\ + - Content may be structured and packaged into modules to facilitate delivering,\n\ + extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\n\ + plug-in fragments ("Fragments"), and features ("Features").\n\ + - Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java(TM) ARchive)\n\ + in a directory named "plugins".\n\ + - A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\n\ + Each Feature may be packaged as a sub-directory in a directory named "features".\n\ + Within a Feature, files named "feature.xml" may contain a list of the names and version\n\ + numbers of the Plug-ins and/or Fragments associated with that Feature.\n\ + - Features may also include other Features ("Included Features"). Within a Feature, files\n\ + named "feature.xml" may contain a list of the names and version numbers of Included Features.\n\ +\n\ +The terms and conditions governing Plug-ins and Fragments should be\n\ +contained in files named "about.html" ("Abouts"). The terms and\n\ +conditions governing Features and Included Features should be contained\n\ +in files named "license.html" ("Feature Licenses"). Abouts and Feature\n\ +Licenses may be located in any directory of a Download or Module\n\ +including, but not limited to the following locations:\n\ +\n\ + - The top-level (root) directory\n\ + - Plug-in and Fragment directories\n\ + - Inside Plug-ins and Fragments packaged as JARs\n\ + - Sub-directories of the directory named "src" of certain Plug-ins\n\ + - Feature directories\n\ +\n\ +Note: if a Feature made available by the Eclipse Foundation is installed using the\n\ +Provisioning Technology (as defined below), you must agree to a license ("Feature \n\ +Update License") during the installation process. If the Feature contains\n\ +Included Features, the Feature Update License should either provide you\n\ +with the terms and conditions governing the Included Features or inform\n\ +you where you can locate them. Feature Update Licenses may be found in\n\ +the "license" property of files named "feature.properties" found within a Feature.\n\ +Such Abouts, Feature Licenses, and Feature Update Licenses contain the\n\ +terms and conditions (or references to such terms and conditions) that\n\ +govern your use of the associated Content in that directory.\n\ +\n\ +THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER\n\ +TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\n\ +SOME OF THESE OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):\n\ +\n\ + - Eclipse Distribution License Version 1.0 (available at http://www.eclipse.org/licenses/edl-v1.0.html)\n\ + - Common Public License Version 1.0 (available at http://www.eclipse.org/legal/cpl-v10.html)\n\ + - Apache Software License 1.1 (available at http://www.apache.org/licenses/LICENSE)\n\ + - Apache Software License 2.0 (available at http://www.apache.org/licenses/LICENSE-2.0)\n\ + - Metro Link Public License 1.00 (available at http://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n\ + - Mozilla Public License Version 1.1 (available at http://www.mozilla.org/MPL/MPL-1.1.html)\n\ +\n\ +IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\n\ +TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License\n\ +is provided, please contact the Eclipse Foundation to determine what terms and conditions\n\ +govern that particular Content.\n\ +\n\ +\n\Use of Provisioning Technology\n\ +\n\ +The Eclipse Foundation makes available provisioning software, examples of which include,\n\ +but are not limited to, p2 and the Eclipse Update Manager ("Provisioning Technology") for\n\ +the purpose of allowing users to install software, documentation, information and/or\n\ +other materials (collectively "Installable Software"). This capability is provided with\n\ +the intent of allowing such users to install, extend and update Eclipse-based products.\n\ +Information about packaging Installable Software is available at\n\ +http://eclipse.org/equinox/p2/repository_packaging.html ("Specification").\n\ +\n\ +You may use Provisioning Technology to allow other parties to install Installable Software.\n\ +You shall be responsible for enabling the applicable license agreements relating to the\n\ +Installable Software to be presented to, and accepted by, the users of the Provisioning Technology\n\ +in accordance with the Specification. By using Provisioning Technology in such a manner and\n\ +making it available in accordance with the Specification, you further acknowledge your\n\ +agreement to, and the acquisition of all necessary rights to permit the following:\n\ +\n\ + 1. A series of actions may occur ("Provisioning Process") in which a user may execute\n\ + the Provisioning Technology on a machine ("Target Machine") with the intent of installing,\n\ + extending or updating the functionality of an Eclipse-based product.\n\ + 2. During the Provisioning Process, the Provisioning Technology may cause third party\n\ + Installable Software or a portion thereof to be accessed and copied to the Target Machine.\n\ + 3. Pursuant to the Specification, you will provide to the user the terms and conditions that\n\ + govern the use of the Installable Software ("Installable Software Agreement") and such\n\ + Installable Software Agreement shall be accessed from the Target Machine in accordance\n\ + with the Specification. Such Installable Software Agreement must inform the user of the\n\ + terms and conditions that govern the Installable Software and must solicit acceptance by\n\ + the end user in the manner prescribed in such Installable Software Agreement. Upon such\n\ + indication of agreement by the user, the provisioning Technology will complete installation\n\ + of the Installable Software.\n\ +\n\ +Cryptography\n\ +\n\ +Content may contain encryption software. The country in which you are\n\ +currently may have restrictions on the import, possession, and use,\n\ +and/or re-export to another country, of encryption software. BEFORE\n\ +using any encryption software, please check the country's laws,\n\ +regulations and policies concerning the import, possession, or use, and\n\ +re-export of encryption software, to see if this is permitted.\n\ +\n\ +Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.\n +########### end of license property ########################################## diff --git a/org.eclipse.osbp.xtext.table.common.feature/feature.xml b/org.eclipse.osbp.xtext.table.common.feature/feature.xml new file mode 100644 index 0000000..0a94d8a --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/feature.xml @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--#======================================================================= --> +<!--# Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) --> +<!--# All rights reserved. This program and the accompanying materials --> +<!--# are made available under the terms of the Eclipse Public License v1.0 --> +<!--# which accompanies this distribution, and is available at --> +<!--# http://www.eclipse.org/legal/epl-v10.html --> +<!--# --> +<!--# Contributors: --> +<!--# Christophe Loetz (Loetz GmbH&Co.KG) - initial API and implementation --> +<!--#======================================================================= --> + +<feature + id="org.eclipse.osbp.xtext.table.common.feature" + label="%featureName" + version="0.9.0.qualifier" + provider-name="%providerName"> + + <description> + %description + </description> + + <copyright> + %copyright + </copyright> + + <license url="%licenseURL"> + %license + </license> + + <plugin + id="org.eclipse.osbp.xtext.table.common" + download-size="0" + install-size="0" + version="0.0.0" + unpack="false"/> + +</feature> diff --git a/org.eclipse.osbp.xtext.table.common.feature/license.html b/org.eclipse.osbp.xtext.table.common.feature/license.html new file mode 100644 index 0000000..6e579a5 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/license.html @@ -0,0 +1,164 @@ +<!--?xml version="1.0" encoding="ISO-8859-1" ?--> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> +<title>Eclipse Foundation Software User Agreement</title> +</head> + +<body lang="EN-US"> +<h2>Eclipse Foundation Software User Agreement</h2> +<p>February 1, 2011</p> + +<h3>Usage Of Content</h3> + +<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS + (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND + CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE + OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR + NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND + CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p> + +<h3>Applicable Licenses</h3> + +<p>Unless otherwise indicated, all Content made available by the Eclipse + Foundation is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 + ("EPL"). A copy of the EPL is provided with this Content and is also + available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. + For purposes of the EPL, "Program" will mean the Content.</p> + +<p>Content includes, but is not limited to, source code, object code, +documentation and other files maintained in the Eclipse Foundation +source code + repository ("Repository") in software modules ("Modules") and made +available as downloadable archives ("Downloads").</p> + +<ul> + <li>Content may be structured and packaged into modules to +facilitate delivering, extending, and upgrading the Content. Typical +modules may include plug-ins ("Plug-ins"), plug-in fragments +("Fragments"), and features ("Features").</li> + <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li> + <li>A Feature is a bundle of one or more Plug-ins and/or +Fragments and associated material. Each Feature may be packaged as a +sub-directory in a directory named "features". Within a Feature, files +named "feature.xml" may contain a list of the names and version numbers +of the Plug-ins + and/or Fragments associated with that Feature.</li> + <li>Features may also include other Features ("Included +Features"). Within a Feature, files named "feature.xml" may contain a +list of the names and version numbers of Included Features.</li> +</ul> + +<p>The terms and conditions governing Plug-ins and Fragments should be +contained in files named "about.html" ("Abouts"). The terms and +conditions governing Features and +Included Features should be contained in files named "license.html" +("Feature Licenses"). Abouts and Feature Licenses may be located in any + directory of a Download or Module +including, but not limited to the following locations:</p> + +<ul> + <li>The top-level (root) directory</li> + <li>Plug-in and Fragment directories</li> + <li>Inside Plug-ins and Fragments packaged as JARs</li> + <li>Sub-directories of the directory named "src" of certain Plug-ins</li> + <li>Feature directories</li> +</ul> + +<p>Note: if a Feature made available by the Eclipse Foundation is +installed using the Provisioning Technology (as defined below), you must + agree to a license ("Feature Update License") during the +installation process. If the Feature contains Included Features, the +Feature Update License should either provide you with the terms and +conditions governing the Included Features or +inform you where you can locate them. Feature Update Licenses may be +found in the "license" property of files named "feature.properties" +found within a Feature. +Such Abouts, Feature Licenses, and Feature Update Licenses contain the +terms and conditions (or references to such terms and conditions) that +govern your use of the associated Content in +that directory.</p> + +<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER +TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. + SOME OF THESE +OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p> + +<ul> + <li>Eclipse Distribution License Version 1.0 (available at <a href="http://www.eclipse.org/licenses/edl-v10.html">http://www.eclipse.org/licenses/edl-v1.0.html</a>)</li> + <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li> + <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li> + <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li> + <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li> + <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li> +</ul> + +<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND +CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, +or Feature Update License is provided, please +contact the Eclipse Foundation to determine what terms and conditions +govern that particular Content.</p> + + +<h3>Use of Provisioning Technology</h3> + +<p>The Eclipse Foundation makes available provisioning software, +examples of which include, but are not limited to, p2 and the Eclipse + Update Manager ("Provisioning Technology") for the purpose of +allowing users to install software, documentation, information and/or + other materials (collectively "Installable Software"). This +capability is provided with the intent of allowing such users to + install, extend and update Eclipse-based products. Information about +packaging Installable Software is available at <a href="http://eclipse.org/equinox/p2/repository_packaging.html">http://eclipse.org/equinox/p2/repository_packaging.html</a> + ("Specification").</p> + +<p>You may use Provisioning Technology to allow other parties to install + Installable Software. You shall be responsible for enabling the + applicable license agreements relating to the Installable Software to + be presented to, and accepted by, the users of the Provisioning +Technology + in accordance with the Specification. By using Provisioning +Technology in such a manner and making it available in accordance with +the + Specification, you further acknowledge your agreement to, and the +acquisition of all necessary rights to permit the following:</p> + +<ol> + <li>A series of actions may occur ("Provisioning Process") in +which a user may execute the Provisioning Technology + on a machine ("Target Machine") with the intent of installing, +extending or updating the functionality of an Eclipse-based + product.</li> + <li>During the Provisioning Process, the Provisioning Technology +may cause third party Installable Software or a portion thereof to be + accessed and copied to the Target Machine.</li> + <li>Pursuant to the Specification, you will provide to the user +the terms and conditions that govern the use of the Installable + Software ("Installable Software Agreement") and such Installable +Software Agreement shall be accessed from the Target + Machine in accordance with the Specification. Such Installable +Software Agreement must inform the user of the terms and conditions that + govern + the Installable Software and must solicit acceptance by the end +user in the manner prescribed in such Installable Software Agreement. +Upon such + indication of agreement by the user, the provisioning Technology +will complete installation of the Installable Software.</li> +</ol> + +<h3>Cryptography</h3> + +<p>Content may contain encryption software. The country in which you are + currently may have restrictions on the import, possession, and use, +and/or re-export to + another country, of encryption software. BEFORE using any encryption +software, please check the country's laws, regulations and policies +concerning the import, + possession, or use, and re-export of encryption software, to see if +this is permitted.</p> + +<p><small>Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.</small></p> + + +</body></html>
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common.feature/pom.xml b/org.eclipse.osbp.xtext.table.common.feature/pom.xml new file mode 100644 index 0000000..cd4418c --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/pom.xml @@ -0,0 +1,82 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--#======================================================================= --> +<!--# Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany). --> +<!--# All rights reserved. This program and the accompanying materials --> +<!--# are made available under the terms of the Eclipse Public License v1.0 --> +<!--# which accompanies this distribution, and is available at --> +<!--# http://www.eclipse.org/legal/epl-v10.html --> +<!--# --> +<!--# Contributors: --> +<!--# Christophe Loetz (Loetz GmbH&Co.KG) - Initial implementation API and implementation --> +<!--#======================================================================= --> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> + <modelVersion>4.0.0</modelVersion> + + <parent> + <groupId>org.eclipse.osbp.xtext.table.common</groupId> + <artifactId>org.eclipse.osbp.xtext.table.common.aggregator</artifactId> + <version>0.9.0-SNAPSHOT</version> + </parent> + + <artifactId>org.eclipse.osbp.xtext.table.common.feature</artifactId> + <packaging>eclipse-feature</packaging> + + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho.extras</groupId> + <artifactId>tycho-source-feature-plugin</artifactId> + <version>${tychoExtrasVersion}</version> + <executions> + <execution> + <id>source-feature</id> + <phase>package</phase> + <goals> + <goal>source-feature</goal> + </goals> + </execution> + </executions> + <configuration> + <labelSuffix> (source)</labelSuffix> + </configuration> + </plugin> + <plugin> + <!-- workaround while bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=398250 + is not fixed --> + <groupId>org.eclipse.tycho</groupId> + <artifactId>tycho-p2-plugin</artifactId> + <version>${tycho-version}</version> + <executions> + <execution> + <id>attached-p2-metadata</id> + <phase>package</phase> + <goals> + <goal>p2-metadata</goal> + </goals> + </execution> + </executions> + </plugin> + <plugin> + <artifactId>maven-javadoc-plugin</artifactId> + <executions> + <execution> + <id>javadoc-jar</id> + <phase>package</phase> + <goals> + <goal>jar</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + + <dependencies> + <dependency> + <groupId>org.eclipse.osbp.xtext.table.common</groupId> + <artifactId>org.eclipse.osbp.xtext.table.common</artifactId> + <version>0.9.0-SNAPSHOT</version> + </dependency> + </dependencies> + +</project> diff --git a/org.eclipse.osbp.xtext.table.common.feature/src/main/javadoc/README.txt b/org.eclipse.osbp.xtext.table.common.feature/src/main/javadoc/README.txt new file mode 100644 index 0000000..831da7e --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/src/main/javadoc/README.txt @@ -0,0 +1 @@ +Resource folder for javadoc resources.
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common.feature/src/overview.html b/org.eclipse.osbp.xtext.table.common.feature/src/overview.html new file mode 100644 index 0000000..a09b472 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common.feature/src/overview.html @@ -0,0 +1,9 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> +<html> +<head> + <title>OSBP Tools Graphical Entity</title> +</head> +<body> +<p>The <strong>OSBP Xtext Table Common </strong>provides common bundles for the OSBP table DSL.</p> +</body> +</html> diff --git a/org.eclipse.osbp.xtext.table.common/.project b/org.eclipse.osbp.xtext.table.common/.project new file mode 100644 index 0000000..b5b9e47 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/.project @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>org.eclipse.osbp.xtext.table.common</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>org.eclipse.xtext.ui.shared.xtextBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.ManifestBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.pde.SchemaBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.babel.editor.rbeBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.sonarlint.eclipse.core.sonarlintBuilder</name> + <arguments> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.m2e.core.maven2Builder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.sonarlint.eclipse.core.sonarlintNature</nature> + <nature>org.eclipse.xtext.ui.shared.xtextNature</nature> + <nature>org.eclipse.m2e.core.maven2Nature</nature> + <nature>org.eclipse.pde.PluginNature</nature> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>org.eclipse.babel.editor.rbeNature</nature> + </natures> +</projectDescription> diff --git a/org.eclipse.osbp.xtext.table.common/LICENSE.txt b/org.eclipse.osbp.xtext.table.common/LICENSE.txt new file mode 100644 index 0000000..ff42ad4 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/LICENSE.txt @@ -0,0 +1,161 @@ +Eclipse Public License -v 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION +OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + +a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and + +b) in the case of each subsequent Contributor: + +i) changes to the Program, and + +ii) additions to the Program; + +where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. +A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone +acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate +modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not +derivative works of the Program. + +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents " mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of +its Contribution alone or when combined with the Program. + +"Program" means the Contributions distributed in accordance with this Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. + +2. GRANT OF RIGHTS + +a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute +and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code +form. + +b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the +Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the +combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such +addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not +apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. + +c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no +assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property +rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity +based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and +licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property +rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the +Program, it is Recipient's responsibility to acquire that license before distributing the Program. + +d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to +grant the copyright license set forth in this Agreement. + +3. REQUIREMENTS + +A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: + +a) it complies with the terms and conditions of this Agreement; and + +b) its license agreement: + +i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including +warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and +fitness for a particular purpose; + +ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, +incidental and consequential damages, such as lost profits; + +iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any +other party; and + +iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it +in a reasonable manner on or through a medium customarily used for software exchange. + +When the Program is made available in source code form: + +a) it must be made available under this Agreement; and + +b) a copy of this Agreement must be included with each copy of the Program. + +Contributors may not remove or alter any copyright notices contained within the Program. + +Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows +subsequent Recipients to identify the originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and +the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes +the Program in a commercial product offering should do so in a manner which does not create potential liability for +other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor +("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") +against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions +brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such +Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The +obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual +property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial +Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the +Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may + participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is +then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties +related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. +Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to +those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, +the Commercial Contributor must pay those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR +CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, +NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for +determining the appropriateness of using and distributing the Program and assumes all risks associated with its +exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance +with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), +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 OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED +HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or +enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such +provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) +alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such +Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such +litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or +conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such +noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution +of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses + granted by Recipient relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement +is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish +new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the +right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may +assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the +Agreement will be given a distinguishing version number. The Program (including Contributions) may always be +distributed subject to the version of the Agreement under which it was received. In addition, after a new version of +the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the +new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to +the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or +otherwise. All rights in the Program not expressly granted under this Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States +of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause +of action arose. Each party waives its rights to a jury trial in any resulting litigation.
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common/META-INF/MANIFEST.MF b/org.eclipse.osbp.xtext.table.common/META-INF/MANIFEST.MF new file mode 100644 index 0000000..12b76a6 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/META-INF/MANIFEST.MF @@ -0,0 +1,35 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: org.eclipse.osbp.xtext.table.common +Bundle-SymbolicName: org.eclipse.osbp.xtext.table.common;singleton:=true +Bundle-Version: 0.9.0.qualifier +Bundle-Activator: org.eclipse.osbp.xtext.table.common.Activator +Require-Bundle: org.eclipse.core.runtime, + org.eclipse.e4.ui.model.workbench;bundle-version="1.1.0", + org.eclipse.e4.ui.workbench, + com.vaadin.client;bundle-version="[7.5.7,7.7.0)", + com.vaadin.server;bundle-version="[7.5.7,7.7.0)", + com.vaadin.shared;bundle-version="[7.5.7,7.7.0)", + org.eclipse.core.databinding;bundle-version="1.4.2", + org.eclipse.core.databinding.beans;bundle-version="1.2.200", + org.eclipse.osbp.runtime.web.vaadin.databinding;bundle-version="[0.9.0,0.10.0)", + org.eclipse.osbp.utils;bundle-version="[0.9.0,0.10.0)", + org.eclipse.osbp.gitinfo;bundle-version="[0.9.0,0.10.0)", + org.jsoup;bundle-version="1.7.2", + filteringtable.osgi;bundle-version="0.9.13" +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 +Bundle-ActivationPolicy: lazy +Import-Package: mondrian.olap, + org.eclipse.osbp.runtime.common.i18n;version="0.9.0", + org.eclipse.osbp.ui.api.datamart;version="0.9.0", + org.eclipse.osbp.ui.api.metadata;version="0.9.0", + org.eclipse.osbp.ui.api.themes;version="0.9.0", + org.eclipse.osbp.utils.blob.component;version="0.9.0", + org.eclipse.osbp.utils.constants;version="0.9.0", + org.eclipse.osbp.utils.themes.ui;version="0.9.0", + org.eclipse.osbp.utils.vaadin;version="0.9.0", + org.eclipse.osbp.xtext.datamart.common.olap;version="0.9.0", + org.eclipse.osbp.xtext.i18n;version="0.9.0", + org.slf4j;resolution:=optional +Export-Package: org.eclipse.osbp.xtext.table.common;version="0.9.0" +Bundle-Vendor: Eclipse OSBP diff --git a/org.eclipse.osbp.xtext.table.common/about.html b/org.eclipse.osbp.xtext.table.common/about.html new file mode 100644 index 0000000..64c0598 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/about.html @@ -0,0 +1,28 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/> +<title>About</title> +</head> +<body lang="EN-US"> +<h2>About This Content</h2> + +<p>June 1, 2016</p> +<h3>License</h3> + +<p>The Eclipse Foundation makes available all content in this plug-in ("Content"). Unless otherwise +indicated below, the Content is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 ("EPL"). A copy of the EPL is available +at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. +For purposes of the EPL, "Program" will mean the Content.</p> + +<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is +being redistributed by another party ("Redistributor") and different terms and conditions may +apply to your use of any object code in the Content. Check the Redistributor's license that was +provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise +indicated below, the terms and conditions of the EPL still apply to any source code in the Content +and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p> + +</body> +</html>
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common/about.ini b/org.eclipse.osbp.xtext.table.common/about.ini new file mode 100644 index 0000000..7df671f --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/about.ini @@ -0,0 +1,17 @@ +# about.ini +# contains information about a feature +# java.io.Properties file (ISO 8859-1 with "\" escapes) +# "%key" are externalized strings defined in about.properties +# This file does not need to be translated. + +# Property "aboutText" contains blurb for "About" dialog (translated) +aboutText=%featureText + +# Property "featureImage" contains path to feature image (32x32) +featureImage= + +# Property "appName" contains name of the application (translated) +appName=%featureName + +# Property "welcomePage" contains path to welcome page (special XML-based format) +welcomePage= diff --git a/org.eclipse.osbp.xtext.table.common/about.mappings b/org.eclipse.osbp.xtext.table.common/about.mappings new file mode 100644 index 0000000..4511a0a --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/about.mappings @@ -0,0 +1,6 @@ +# about.mappings +# contains fill-ins for about.properties +# java.io.Properties file (ISO 8859-1 with "\" escapes) +# This file does not need to be translated. + +0=qualifier diff --git a/org.eclipse.osbp.xtext.table.common/about.properties b/org.eclipse.osbp.xtext.table.common/about.properties new file mode 100644 index 0000000..b0ad09e --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/about.properties @@ -0,0 +1,26 @@ +# +# Copyright (c) 2012, 2016 - Loetz GmbH&Co.KG (Heidelberg) +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# Christophe Loetz (Loetz GmbH&Co.KG) - initial API and implementation +# + +# NLS_MESSAGEFORMAT_VAR + +featureName=org.eclipse.osbp.xtext.table.common + +################ blurb property #################################### +featureText=\ +Copyright (c) 2012-2016 - Loetz GmbH&Co.KG \n\ +All rights reserved. This program and the accompanying materials\n\ +are made available under the terms of the Eclipse Public License v1.0\n\ +which accompanies this distribution, and is available at\n\ +http://www.eclipse.org/legal/epl-v10.html\n\ +\n\ +Contributors:\n\ + Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation\n +################ end of blurb property #################################### diff --git a/org.eclipse.osbp.xtext.table.common/build.properties b/org.eclipse.osbp.xtext.table.common/build.properties new file mode 100644 index 0000000..2fb529b --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/build.properties @@ -0,0 +1,12 @@ +source.. = src/ +output.. = target/classes/ +bin.includes = about.properties, about.mappings, about.ini, about.html, META-INF/,\ + .,\ + .settings/,\ + plugin.xml,\ + license.html,\ + LICENSE.txt,\ + epl-v10.html +src.includes = about.properties, about.mappings, about.ini, about.html, license.html,\ + LICENSE.txt,\ + epl-v10.html diff --git a/org.eclipse.osbp.xtext.table.common/epl-v10.html b/org.eclipse.osbp.xtext.table.common/epl-v10.html new file mode 100644 index 0000000..b398acc --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/epl-v10.html @@ -0,0 +1,259 @@ +<!--?xml version="1.0" encoding="ISO-8859-1" ?--> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> +<title>Eclipse Public License - Version 1.0</title> +<style type="text/css"> + body { + size: 8.5in 11.0in; + margin: 0.25in 0.5in 0.25in 0.5in; + tab-interval: 0.5in; + } + p { + margin-left: auto; + margin-top: 0.5em; + margin-bottom: 0.5em; + } + p.list { + margin-left: 0.5in; + margin-top: 0.05em; + margin-bottom: 0.05em; + } + </style> + +</head> + +<body lang="EN-US"> + +<h2>Eclipse Public License - v 1.0</h2> + +<p>THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE +PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR +DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS +AGREEMENT.</p> + +<p><b>1. DEFINITIONS</b></p> + +<p>"Contribution" means:</p> + +<p class="list">a) in the case of the initial Contributor, the initial +code and documentation distributed under this Agreement, and</p> +<p class="list">b) in the case of each subsequent Contributor:</p> +<p class="list">i) changes to the Program, and</p> +<p class="list">ii) additions to the Program;</p> +<p class="list">where such changes and/or additions to the Program +originate from and are distributed by that particular Contributor. A +Contribution 'originates' from a Contributor if it was added to the +Program by such Contributor itself or anyone acting on such +Contributor's behalf. Contributions do not include additions to the +Program which: (i) are separate modules of software distributed in +conjunction with the Program under their own license agreement, and (ii) +are not derivative works of the Program.</p> + +<p>"Contributor" means any person or entity that distributes +the Program.</p> + +<p>"Licensed Patents" mean patent claims licensable by a +Contributor which are necessarily infringed by the use or sale of its +Contribution alone or when combined with the Program.</p> + +<p>"Program" means the Contributions distributed in accordance +with this Agreement.</p> + +<p>"Recipient" means anyone who receives the Program under +this Agreement, including all Contributors.</p> + +<p><b>2. GRANT OF RIGHTS</b></p> + +<p class="list">a) Subject to the terms of this Agreement, each +Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free copyright license to reproduce, prepare derivative works +of, publicly display, publicly perform, distribute and sublicense the +Contribution of such Contributor, if any, and such derivative works, in +source code and object code form.</p> + +<p class="list">b) Subject to the terms of this Agreement, each +Contributor hereby grants Recipient a non-exclusive, worldwide, +royalty-free patent license under Licensed Patents to make, use, sell, +offer to sell, import and otherwise transfer the Contribution of such +Contributor, if any, in source code and object code form. This patent +license shall apply to the combination of the Contribution and the +Program if, at the time the Contribution is added by the Contributor, +such addition of the Contribution causes such combination to be covered +by the Licensed Patents. The patent license shall not apply to any other +combinations which include the Contribution. No hardware per se is +licensed hereunder.</p> + +<p class="list">c) Recipient understands that although each Contributor +grants the licenses to its Contributions set forth herein, no assurances +are provided by any Contributor that the Program does not infringe the +patent or other intellectual property rights of any other entity. Each +Contributor disclaims any liability to Recipient for claims brought by +any other entity based on infringement of intellectual property rights +or otherwise. As a condition to exercising the rights and licenses +granted hereunder, each Recipient hereby assumes sole responsibility to +secure any other intellectual property rights needed, if any. For +example, if a third party patent license is required to allow Recipient +to distribute the Program, it is Recipient's responsibility to acquire +that license before distributing the Program.</p> + +<p class="list">d) Each Contributor represents that to its knowledge it +has sufficient copyright rights in its Contribution, if any, to grant +the copyright license set forth in this Agreement.</p> + +<p><b>3. REQUIREMENTS</b></p> + +<p>A Contributor may choose to distribute the Program in object code +form under its own license agreement, provided that:</p> + +<p class="list">a) it complies with the terms and conditions of this +Agreement; and</p> + +<p class="list">b) its license agreement:</p> + +<p class="list">i) effectively disclaims on behalf of all Contributors +all warranties and conditions, express and implied, including warranties +or conditions of title and non-infringement, and implied warranties or +conditions of merchantability and fitness for a particular purpose;</p> + +<p class="list">ii) effectively excludes on behalf of all Contributors +all liability for damages, including direct, indirect, special, +incidental and consequential damages, such as lost profits;</p> + +<p class="list">iii) states that any provisions which differ from this +Agreement are offered by that Contributor alone and not by any other +party; and</p> + +<p class="list">iv) states that source code for the Program is available +from such Contributor, and informs licensees how to obtain it in a +reasonable manner on or through a medium customarily used for software +exchange.</p> + +<p>When the Program is made available in source code form:</p> + +<p class="list">a) it must be made available under this Agreement; and</p> + +<p class="list">b) a copy of this Agreement must be included with each +copy of the Program.</p> + +<p>Contributors may not remove or alter any copyright notices contained +within the Program.</p> + +<p>Each Contributor must identify itself as the originator of its +Contribution, if any, in a manner that reasonably allows subsequent +Recipients to identify the originator of the Contribution.</p> + +<p><b>4. COMMERCIAL DISTRIBUTION</b></p> + +<p>Commercial distributors of software may accept certain +responsibilities with respect to end users, business partners and the +like. While this license is intended to facilitate the commercial use of +the Program, the Contributor who includes the Program in a commercial +product offering should do so in a manner which does not create +potential liability for other Contributors. Therefore, if a Contributor +includes the Program in a commercial product offering, such Contributor +("Commercial Contributor") hereby agrees to defend and +indemnify every other Contributor ("Indemnified Contributor") +against any losses, damages and costs (collectively "Losses") +arising from claims, lawsuits and other legal actions brought by a third +party against the Indemnified Contributor to the extent caused by the +acts or omissions of such Commercial Contributor in connection with its +distribution of the Program in a commercial product offering. The +obligations in this section do not apply to any claims or Losses +relating to any actual or alleged intellectual property infringement. In +order to qualify, an Indemnified Contributor must: a) promptly notify +the Commercial Contributor in writing of such claim, and b) allow the +Commercial Contributor to control, and cooperate with the Commercial +Contributor in, the defense and any related settlement negotiations. The +Indemnified Contributor may participate in any such claim at its own +expense.</p> + +<p>For example, a Contributor might include the Program in a commercial +product offering, Product X. That Contributor is then a Commercial +Contributor. If that Commercial Contributor then makes performance +claims, or offers warranties related to Product X, those performance +claims and warranties are such Commercial Contributor's responsibility +alone. Under this section, the Commercial Contributor would have to +defend claims against the other Contributors related to those +performance claims and warranties, and if a court requires any other +Contributor to pay any damages as a result, the Commercial Contributor +must pay those damages.</p> + +<p><b>5. NO WARRANTY</b></p> + +<p>EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS +PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS +OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, +ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY +OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely +responsible for determining the appropriateness of using and +distributing the Program and assumes all risks associated with its +exercise of rights under this Agreement , including but not limited to +the risks and costs of program errors, compliance with applicable laws, +damage to or loss of data, programs or equipment, and unavailability or +interruption of operations.</p> + +<p><b>6. DISCLAIMER OF LIABILITY</b></p> + +<p>EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT +NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, +INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING +WITHOUT LIMITATION LOST PROFITS), 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 OR +DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED +HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</p> + +<p><b>7. GENERAL</b></p> + +<p>If any provision of this Agreement is invalid or unenforceable under +applicable law, it shall not affect the validity or enforceability of +the remainder of the terms of this Agreement, and without further action +by the parties hereto, such provision shall be reformed to the minimum +extent necessary to make such provision valid and enforceable.</p> + +<p>If Recipient institutes patent litigation against any entity +(including a cross-claim or counterclaim in a lawsuit) alleging that the +Program itself (excluding combinations of the Program with other +software or hardware) infringes such Recipient's patent(s), then such +Recipient's rights granted under Section 2(b) shall terminate as of the +date such litigation is filed.</p> + +<p>All Recipient's rights under this Agreement shall terminate if it +fails to comply with any of the material terms or conditions of this +Agreement and does not cure such failure in a reasonable period of time +after becoming aware of such noncompliance. If all Recipient's rights +under this Agreement terminate, Recipient agrees to cease use and +distribution of the Program as soon as reasonably practicable. However, +Recipient's obligations under this Agreement and any licenses granted by +Recipient relating to the Program shall continue and survive.</p> + +<p>Everyone is permitted to copy and distribute copies of this +Agreement, but in order to avoid inconsistency the Agreement is +copyrighted and may only be modified in the following manner. The +Agreement Steward reserves the right to publish new versions (including +revisions) of this Agreement from time to time. No one other than the +Agreement Steward has the right to modify this Agreement. The Eclipse +Foundation is the initial Agreement Steward. The Eclipse Foundation may +assign the responsibility to serve as the Agreement Steward to a +suitable separate entity. Each new version of the Agreement will be +given a distinguishing version number. The Program (including +Contributions) may always be distributed subject to the version of the +Agreement under which it was received. In addition, after a new version +of the Agreement is published, Contributor may elect to distribute the +Program (including its Contributions) under the new version. Except as +expressly stated in Sections 2(a) and 2(b) above, Recipient receives no +rights or licenses to the intellectual property of any Contributor under +this Agreement, whether expressly, by implication, estoppel or +otherwise. All rights in the Program not expressly granted under this +Agreement are reserved.</p> + +<p>This Agreement is governed by the laws of the State of New York and +the intellectual property laws of the United States of America. No party +to this Agreement will bring a legal action under this Agreement more +than one year after the cause of action arose. Each party waives its +rights to a jury trial in any resulting litigation.</p> + + + +</body></html>
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common/license.html b/org.eclipse.osbp.xtext.table.common/license.html new file mode 100644 index 0000000..6e579a5 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/license.html @@ -0,0 +1,164 @@ +<!--?xml version="1.0" encoding="ISO-8859-1" ?--> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"><head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> +<title>Eclipse Foundation Software User Agreement</title> +</head> + +<body lang="EN-US"> +<h2>Eclipse Foundation Software User Agreement</h2> +<p>February 1, 2011</p> + +<h3>Usage Of Content</h3> + +<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS + (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND + CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE + OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR + NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND + CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p> + +<h3>Applicable Licenses</h3> + +<p>Unless otherwise indicated, all Content made available by the Eclipse + Foundation is provided to you under the terms and conditions of the +Eclipse Public License Version 1.0 + ("EPL"). A copy of the EPL is provided with this Content and is also + available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. + For purposes of the EPL, "Program" will mean the Content.</p> + +<p>Content includes, but is not limited to, source code, object code, +documentation and other files maintained in the Eclipse Foundation +source code + repository ("Repository") in software modules ("Modules") and made +available as downloadable archives ("Downloads").</p> + +<ul> + <li>Content may be structured and packaged into modules to +facilitate delivering, extending, and upgrading the Content. Typical +modules may include plug-ins ("Plug-ins"), plug-in fragments +("Fragments"), and features ("Features").</li> + <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li> + <li>A Feature is a bundle of one or more Plug-ins and/or +Fragments and associated material. Each Feature may be packaged as a +sub-directory in a directory named "features". Within a Feature, files +named "feature.xml" may contain a list of the names and version numbers +of the Plug-ins + and/or Fragments associated with that Feature.</li> + <li>Features may also include other Features ("Included +Features"). Within a Feature, files named "feature.xml" may contain a +list of the names and version numbers of Included Features.</li> +</ul> + +<p>The terms and conditions governing Plug-ins and Fragments should be +contained in files named "about.html" ("Abouts"). The terms and +conditions governing Features and +Included Features should be contained in files named "license.html" +("Feature Licenses"). Abouts and Feature Licenses may be located in any + directory of a Download or Module +including, but not limited to the following locations:</p> + +<ul> + <li>The top-level (root) directory</li> + <li>Plug-in and Fragment directories</li> + <li>Inside Plug-ins and Fragments packaged as JARs</li> + <li>Sub-directories of the directory named "src" of certain Plug-ins</li> + <li>Feature directories</li> +</ul> + +<p>Note: if a Feature made available by the Eclipse Foundation is +installed using the Provisioning Technology (as defined below), you must + agree to a license ("Feature Update License") during the +installation process. If the Feature contains Included Features, the +Feature Update License should either provide you with the terms and +conditions governing the Included Features or +inform you where you can locate them. Feature Update Licenses may be +found in the "license" property of files named "feature.properties" +found within a Feature. +Such Abouts, Feature Licenses, and Feature Update Licenses contain the +terms and conditions (or references to such terms and conditions) that +govern your use of the associated Content in +that directory.</p> + +<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER +TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. + SOME OF THESE +OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p> + +<ul> + <li>Eclipse Distribution License Version 1.0 (available at <a href="http://www.eclipse.org/licenses/edl-v10.html">http://www.eclipse.org/licenses/edl-v1.0.html</a>)</li> + <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li> + <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li> + <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li> + <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li> + <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li> +</ul> + +<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND +CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, +or Feature Update License is provided, please +contact the Eclipse Foundation to determine what terms and conditions +govern that particular Content.</p> + + +<h3>Use of Provisioning Technology</h3> + +<p>The Eclipse Foundation makes available provisioning software, +examples of which include, but are not limited to, p2 and the Eclipse + Update Manager ("Provisioning Technology") for the purpose of +allowing users to install software, documentation, information and/or + other materials (collectively "Installable Software"). This +capability is provided with the intent of allowing such users to + install, extend and update Eclipse-based products. Information about +packaging Installable Software is available at <a href="http://eclipse.org/equinox/p2/repository_packaging.html">http://eclipse.org/equinox/p2/repository_packaging.html</a> + ("Specification").</p> + +<p>You may use Provisioning Technology to allow other parties to install + Installable Software. You shall be responsible for enabling the + applicable license agreements relating to the Installable Software to + be presented to, and accepted by, the users of the Provisioning +Technology + in accordance with the Specification. By using Provisioning +Technology in such a manner and making it available in accordance with +the + Specification, you further acknowledge your agreement to, and the +acquisition of all necessary rights to permit the following:</p> + +<ol> + <li>A series of actions may occur ("Provisioning Process") in +which a user may execute the Provisioning Technology + on a machine ("Target Machine") with the intent of installing, +extending or updating the functionality of an Eclipse-based + product.</li> + <li>During the Provisioning Process, the Provisioning Technology +may cause third party Installable Software or a portion thereof to be + accessed and copied to the Target Machine.</li> + <li>Pursuant to the Specification, you will provide to the user +the terms and conditions that govern the use of the Installable + Software ("Installable Software Agreement") and such Installable +Software Agreement shall be accessed from the Target + Machine in accordance with the Specification. Such Installable +Software Agreement must inform the user of the terms and conditions that + govern + the Installable Software and must solicit acceptance by the end +user in the manner prescribed in such Installable Software Agreement. +Upon such + indication of agreement by the user, the provisioning Technology +will complete installation of the Installable Software.</li> +</ol> + +<h3>Cryptography</h3> + +<p>Content may contain encryption software. The country in which you are + currently may have restrictions on the import, possession, and use, +and/or re-export to + another country, of encryption software. BEFORE using any encryption +software, please check the country's laws, regulations and policies +concerning the import, + possession, or use, and re-export of encryption software, to see if +this is permitted.</p> + +<p><small>Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.</small></p> + + +</body></html>
\ No newline at end of file diff --git a/org.eclipse.osbp.xtext.table.common/notice.html b/org.eclipse.osbp.xtext.table.common/notice.html new file mode 100644 index 0000000..c3d34c3 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/notice.html @@ -0,0 +1,107 @@ +<?xml version="1.0" encoding="ISO-8859-1" ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml"> +<head> +<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" /> +<title>Eclipse Foundation Software User Agreement</title> +</head> + +<body lang="EN-US"> +<h2>Eclipse Foundation Software User Agreement</h2> +<p>April 9, 2014</p> + +<h3>Usage Of Content</h3> + +<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS + (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND + CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE + OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR + NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND + CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p> + +<h3>Applicable Licenses</h3> + +<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0 + ("EPL"). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>. + For purposes of the EPL, "Program" will mean the Content.</p> + +<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse Foundation source code + repository ("Repository") in software modules ("Modules") and made available as downloadable archives ("Downloads").</p> + +<ul> + <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").</li> + <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li> + <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins + and/or Fragments associated with that Feature.</li> + <li>Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.</li> +</ul> + +<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and +Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module +including, but not limited to the following locations:</p> + +<ul> + <li>The top-level (root) directory</li> + <li>Plug-in and Fragment directories</li> + <li>Inside Plug-ins and Fragments packaged as JARs</li> + <li>Sub-directories of the directory named "src" of certain Plug-ins</li> + <li>Feature directories</li> +</ul> + +<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Provisioning Technology (as defined below), you must agree to a license ("Feature Update License") during the +installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or +inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature. +Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in +that directory.</p> + +<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE +OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p> + +<ul> + <li>Eclipse Distribution License Version 1.0 (available at <a href="http://www.eclipse.org/licenses/edl-v10.html">http://www.eclipse.org/licenses/edl-v1.0.html</a>)</li> + <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li> + <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li> + <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li> + <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li> +</ul> + +<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please +contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p> + + +<h3>Use of Provisioning Technology</h3> + +<p>The Eclipse Foundation makes available provisioning software, examples of which include, but are not limited to, p2 and the Eclipse + Update Manager ("Provisioning Technology") for the purpose of allowing users to install software, documentation, information and/or + other materials (collectively "Installable Software"). This capability is provided with the intent of allowing such users to + install, extend and update Eclipse-based products. Information about packaging Installable Software is available at <a + href="http://eclipse.org/equinox/p2/repository_packaging.html">http://eclipse.org/equinox/p2/repository_packaging.html</a> + ("Specification").</p> + +<p>You may use Provisioning Technology to allow other parties to install Installable Software. You shall be responsible for enabling the + applicable license agreements relating to the Installable Software to be presented to, and accepted by, the users of the Provisioning Technology + in accordance with the Specification. By using Provisioning Technology in such a manner and making it available in accordance with the + Specification, you further acknowledge your agreement to, and the acquisition of all necessary rights to permit the following:</p> + +<ol> + <li>A series of actions may occur ("Provisioning Process") in which a user may execute the Provisioning Technology + on a machine ("Target Machine") with the intent of installing, extending or updating the functionality of an Eclipse-based + product.</li> + <li>During the Provisioning Process, the Provisioning Technology may cause third party Installable Software or a portion thereof to be + accessed and copied to the Target Machine.</li> + <li>Pursuant to the Specification, you will provide to the user the terms and conditions that govern the use of the Installable + Software ("Installable Software Agreement") and such Installable Software Agreement shall be accessed from the Target + Machine in accordance with the Specification. Such Installable Software Agreement must inform the user of the terms and conditions that govern + the Installable Software and must solicit acceptance by the end user in the manner prescribed in such Installable Software Agreement. Upon such + indication of agreement by the user, the provisioning Technology will complete installation of the Installable Software.</li> +</ol> + +<h3>Cryptography</h3> + +<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to + another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import, + possession, or use, and re-export of encryption software, to see if this is permitted.</p> + +<p><small>Java and all Java-based trademarks are trademarks of Oracle Corporation in the United States, other countries, or both.</small></p> +</body> +</html> diff --git a/org.eclipse.osbp.xtext.table.common/plugin.properties b/org.eclipse.osbp.xtext.table.common/plugin.properties new file mode 100644 index 0000000..bcd2565 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/plugin.properties @@ -0,0 +1,4 @@ +# + +pluginName = OS.bee table common +providerName = Loetz GmbH&Co.KG, 69115 Heidelberg, Germany diff --git a/org.eclipse.osbp.xtext.table.common/plugin.xml b/org.eclipse.osbp.xtext.table.common/plugin.xml new file mode 100644 index 0000000..43a5dae --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/plugin.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?eclipse version="3.0"?> + +<plugin> + +</plugin> diff --git a/org.eclipse.osbp.xtext.table.common/pom.xml b/org.eclipse.osbp.xtext.table.common/pom.xml new file mode 100644 index 0000000..fdcc52e --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/pom.xml @@ -0,0 +1,46 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--#======================================================================= --> +<!--# Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) --> +<!--# All rights reserved. This program and the accompanying materials --> +<!--# are made available under the terms of the Eclipse Public License v1.0 --> +<!--# which accompanies this distribution, and is available at --> +<!--# http://www.eclipse.org/legal/epl-v10.html --> +<!--# --> +<!--# Contributors: --> +<!--# Christophe Loetz (Loetz GmbH&Co.KG) - initial API and implementation --> +<!--#======================================================================= --> + +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + <modelVersion>4.0.0</modelVersion> + <parent> + <groupId>org.eclipse.osbp.xtext.table.common</groupId> + <artifactId>org.eclipse.osbp.xtext.table.common.aggregator</artifactId> + <version>0.9.0-SNAPSHOT</version> + <relativePath>..</relativePath> + </parent> + <artifactId>org.eclipse.osbp.xtext.table.common</artifactId> + <build> + <sourceDirectory>emf-gen</sourceDirectory> + <resources> + <resource> + <directory>src</directory> + <excludes> + <exclude>**/*.java</exclude> + </excludes> + </resource> + <resource> + <directory>src-gen</directory> + <excludes> + <exclude>**/*.java</exclude> + </excludes> + </resource> + <resource> + <directory>xtend-gen</directory> + <excludes> + <exclude>**/*.java</exclude> + </excludes> + </resource> + </resources> + </build> + <packaging>eclipse-plugin</packaging> +</project> diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/Activator.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/Activator.java new file mode 100644 index 0000000..d1e1538 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/Activator.java @@ -0,0 +1,46 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import org.eclipse.osbp.gitinfo.Loginfo; +import org.osgi.framework.BundleActivator; +import org.osgi.framework.BundleContext; + +public class Activator implements BundleActivator { + + private static BundleContext context; + + static BundleContext getContext() { + return context; + } + + /* + * (non-Javadoc) + * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext) + */ + public void start(BundleContext bundleContext) throws Exception { + Activator.context = bundleContext; + Loginfo li = new Loginfo(); + li.print( Activator.class.getCanonicalName(), Activator.class.getClassLoader()); + } + + /* + * (non-Javadoc) + * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext) + */ + public void stop(BundleContext bundleContext) throws Exception { + Activator.context = null; + } + +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetFilterTable.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetFilterTable.java new file mode 100644 index 0000000..c55229f --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetFilterTable.java @@ -0,0 +1,46 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import java.util.Locale; + +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedPosition; +import org.tepi.filtertable.FilterTable; + +public class CellSetFilterTable extends FilterTable { + + /** + * + */ + private static final long serialVersionUID = -1518393043555657561L; + + @Override + public String getColumnHeader(Object propertyId) { + if (getColumnHeaderMode() == ColumnHeaderMode.HIDDEN) { + return null; + } + DerivedPosition column = ((CellSetIndexedContainer)getContainerDataSource()).getColumnPosition(propertyId); + if (column != null) { + return column.toString(super.getLocale()); + } + return propertyId.toString(); + } + + @Override + public void setLocale(Locale locale) { + super.setLocale(locale); + resetFilters(); + } + +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetIndexedContainer.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetIndexedContainer.java new file mode 100644 index 0000000..f275fd7 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetIndexedContainer.java @@ -0,0 +1,798 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ +package org.eclipse.osbp.xtext.table.common; + +import java.math.BigDecimal; +import java.sql.Timestamp; +import java.util.ArrayList; +import java.util.Date; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Locale; +import java.util.Map; + +import org.eclipse.osbp.ui.api.datamart.DerivedOlapException; +import org.eclipse.osbp.ui.api.metadata.IDSLMetadataService; +import org.eclipse.osbp.ui.api.themes.IThemeResourceService; +import org.eclipse.osbp.utils.blob.component.BlobUploadComponent; +import org.eclipse.osbp.utils.vaadin.CellSetImage; +import org.eclipse.osbp.utils.vaadin.PropertyLookup; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedAxis; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedCell; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedCellSet; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedMember; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedPosition; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.tepi.filtertable.FilterTable; +import org.tepi.filtertable.paged.PagedFilterTable; + +import com.vaadin.data.Property.ReadOnlyException; +import com.vaadin.data.util.IndexedContainer; +import com.vaadin.ui.AbstractSelect; +import com.vaadin.ui.Component; +import com.vaadin.ui.CustomTable; + +public class CellSetIndexedContainer extends IndexedContainer { + private static final long serialVersionUID = 5556029714794178000L; + private static final Logger log = LoggerFactory.getLogger(CellSetIndexedContainer.class); + + private Map<String, PropertyLookup> propertyLookupMap = new HashMap<>(); + + private DerivedCellSet cellSet = null; + private List<Integer> coordinateSystem = null; + private Map<Integer, PositionInfo> positionMap = new HashMap<>(); + + private String rowStyle = null; + + private final IThemeResourceService themeResourceService; + private final IDSLMetadataService dslMetadataService; + + private boolean isCrossTab = false; + private Locale locale; + + public CellSetIndexedContainer(IDSLMetadataService dslMetadataService, Locale locale, IThemeResourceService themeResourceService, + Map<String, PropertyLookup> propertyLookupMap, final DerivedCellSet cellSet, List<Integer> coordinateSystem, boolean isCrossTab) throws ReadOnlyException, + DerivedOlapException { + super(); + this.themeResourceService = themeResourceService; + this.dslMetadataService = dslMetadataService; + this.cellSet = cellSet; + this.coordinateSystem = coordinateSystem; + this.isCrossTab = isCrossTab; + this.setLocale(locale); + addPropertyLookup(propertyLookupMap); + fillContainer(); + } + + public List<Object> getAllItemIds() { + return super.getAllItemIds(); + } + + public List<Object> getFilteredItemIds() { + return super.getFilteredItemIds(); + } + + public DerivedCellSet getCellSet() { + return cellSet; + } + + public void setCellSet(DerivedCellSet cellSet) { + this.cellSet = cellSet; + } + + public String getRowStyle() { + return rowStyle; + } + + public void setRowStyle(String rowStyle) { + this.rowStyle = rowStyle; + } + + public Map<String, PropertyLookup> getPropertyLookupMap() { + return propertyLookupMap; + } + + public void addPropertyLookup(Map<String, PropertyLookup> propertyLookupMap) { + this.propertyLookupMap.putAll(propertyLookupMap); + } + + public void addPropertyLookup(String columnName, PropertyLookup lookup) { + propertyLookupMap.put(columnName, lookup); + } + + public void removePropertyLookup(String columnName) { + if (propertyLookupMap.containsKey(columnName)) { + propertyLookupMap.remove(columnName); + } + } + + public DerivedPosition getColumnPosition(Object propertyId) { + if (positionMap.containsKey((Integer) propertyId)) { + return positionMap.get((Integer) propertyId).getPosition(); + } + return null; + } + + public Class<?> getColumnType(Object propertyId) { + if (positionMap.containsKey((Integer) propertyId)) { + return positionMap.get((Integer) propertyId).getType(); + } + return null; + } + + private PropertyLookup findColumnProperty(DerivedPosition column) { + String colName = column.toUppercaseString(); + for (String key : propertyLookupMap.keySet()) { + // in cross tabs we must allow partly match + if (isCrossTab) { + if (colName.contains(key)) { + return propertyLookupMap.get(key); + } + } else { + if (colName.equals(key)) { + return propertyLookupMap.get(key); + } + } + } + return null; + } + + private boolean addCellSetContainerProperty(DerivedPosition column, Object value, Object defaultValue, boolean isHeader) { + PropertyLookup lookup = null; + // resolve ordinal column properties + String tmpColname = "#"; + if (isHeader) { + tmpColname += "ROWS"; + } else { + tmpColname += "COLUMNS"; + } + tmpColname += (new Integer(column.getOrdinal())).toString(); + if (propertyLookupMap.containsKey(tmpColname)) { + propertyLookupMap.put(column.toUppercaseString(), propertyLookupMap.remove(tmpColname)); + } + + // resolve all columns properties + tmpColname = "?"; + if (isHeader) { + tmpColname += "ROWS"; + } else { + tmpColname += "COLUMNS"; + } + if (propertyLookupMap.containsKey(tmpColname)) { + propertyLookupMap.put(column.toUppercaseString(), propertyLookupMap.get(tmpColname)); + } + + // for crossjoined cube columns the column name is a combination of both, so a partly match is ok + lookup = findColumnProperty(column); + // add default styles if not found + if (lookup == null) { + lookup = new PropertyLookup(themeResourceService, dslMetadataService, locale); + addPropertyLookup(column.toUppercaseString(), lookup); + } + Class<?> type = String.class; + if (value != null) { + // change type if applied + type = lookup.getPropertyType(value.getClass()); + } + // add default styles + lookup.setDefaultStyle(type, isHeader); + // create position map + positionMap.put(column.getOrdinal(), new PositionInfo(column, lookup.getValueObject(value))); + return addContainerProperty(column.getOrdinal(), type, defaultValue); + } + + @SuppressWarnings("unchecked") + private boolean setCellSetContainerValue(DerivedPosition row, DerivedPosition column, Object value) { + PropertyLookup lookup = findColumnProperty(column); + if (lookup != null) { + if (getContainerProperty(row.getOrdinal(), column.getOrdinal()) != null) { + getContainerProperty(row.getOrdinal(), column.getOrdinal()).setValue(lookup.getValueObject(value)); + } + return true; + } + if (!getContainerProperty(row.getOrdinal(), column.getOrdinal()).getType().isAssignableFrom(value.getClass())) { + return false; + } + getContainerProperty(row.getOrdinal(), column.getOrdinal()).setValue(value); + return true; + } + + private DerivedPosition findColumn(String columnName) { + for (DerivedPosition column : cellSet.getAxes().get(DerivedAxis.AXIS_COLUMNS).getPositions()) { + if (columnName.equals(column.toUppercaseString())) { + return column; + } + } + return null; + } + + public Object getOrdinalCellValue(Integer rowOrdinal, String columnName) throws DerivedOlapException { + return getCellValue(cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositionByOrdinal(rowOrdinal), findColumn(columnName)); + } + + public Object getCellValue(DerivedPosition row, DerivedPosition column) throws DerivedOlapException { + if (row == null || column == null || row.getOrdinal() == -1 || column.getOrdinal() == -1) { + return null; + } + List<Integer> coordinates = new ArrayList<>(coordinateSystem); + coordinates.set(DerivedAxis.AXIS_ROWS, row.getOrdinal()); + coordinates.set(DerivedAxis.AXIS_COLUMNS, column.getOrdinal()); + return cellSet.getCell(coordinates).getValue(); + } + + private boolean objectChanged(Object newValue, Object oldValue) { + if ((newValue == null && oldValue != null) || (newValue != null && oldValue == null)) { + return true; + } + if (newValue == null && oldValue == null) { // NOSONAR + return false; + } + if (newValue.getClass().equals(double.class)) { + if (Double.compare((double) newValue, (double) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Double.class)) { + if (((Double) newValue).compareTo((Double) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(float.class)) { + if (Float.compare((float) newValue, (float) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Float.class)) { + if (((Float) newValue).compareTo((Float) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(int.class)) { + if (Integer.compare((int) newValue, (int) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Integer.class)) { + if (((Integer) newValue).compareTo((Integer) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(long.class)) { + if (Long.compare((long) newValue, (long) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Long.class)) { + if (((Long) newValue).compareTo((Long) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(BigDecimal.class)) { + if (((BigDecimal) newValue).compareTo((BigDecimal) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(String.class)) { + if (((String) newValue).compareTo((String) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Date.class)) { + if (((Date) newValue).compareTo((Date) oldValue) != 0) + return true; + } else if (newValue.getClass().equals(Timestamp.class)) { + if (((Timestamp) newValue).compareTo((Timestamp) oldValue) != 0) + return true; + } + return false; + } + + private void createRow(DerivedPosition row) { + addItem(row.getOrdinal()); + for (DerivedMember member : row.getMembers()) { + String[] tokens = member.getUniqueName().split("\\]\\.\\["); + for (int token = 1; token < tokens.length; token++) { + if (!positionMap.containsKey(-1 * token)) { + DerivedPosition position = new DerivedPosition(row.getMembers(), -1 * token, row.getContainer()); + addCellSetContainerProperty(position, "", null, true); + } + setCellSetContainerValue(row, positionMap.get(-1 * token).getPosition(), tokens[token].replace("]", "")); + } + } + } + + private void createColumn(DerivedPosition row, DerivedPosition column) { + List<Integer> coordinates = new ArrayList<>(coordinateSystem); + coordinates.set(DerivedAxis.AXIS_ROWS, row.getOrdinal()); + coordinates.set(DerivedAxis.AXIS_COLUMNS, column.getOrdinal()); + Object value = null; + try { + value = cellSet.getCell(coordinates).getValue(); + } catch (DerivedOlapException e) { + } // NOSONAR - exception is not of interest + if (value != null) { + if (getContainerProperty(row.getOrdinal(), column.getOrdinal()) == null) { + addCellSetContainerProperty(column, value, null, false); + } + setCellSetContainerValue(row, column, value); + } else { + log.debug("'null' value on row:" + row.getOrdinal() + "/column:" + column.getOrdinal() + ", thus no cell created"); + } + } + + public void clearContainer() { + removeAllContainerFilters(); + removeAllItems(); + } + + public boolean updateContainer(final DerivedCellSet newCellSet) { + Iterator<DerivedPosition> oldIterator = cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositions().iterator(); + if (!oldIterator.hasNext()) { + removeAllContainerFilters(); + removeAllItems(); + log.debug("old cellset is empty - full refresh"); + return false; + } + if (newCellSet == null) { + removeAllContainerFilters(); + removeAllItems(); + log.debug("new cellset is empty - full refresh"); + return false; + } + List<Integer> coordinatesForBoth = new ArrayList<>(coordinateSystem); + for (DerivedPosition newRow : newCellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositions()) { + boolean rowFound = true; + DerivedPosition oldRow = null; + if (oldIterator.hasNext()) { + oldRow = oldIterator.next(); + } else { + rowFound = false; + log.debug("row not found - append"); + } + coordinatesForBoth.set(DerivedAxis.AXIS_ROWS, newRow.getOrdinal()); + if (rowFound) { + try { + if (!cellSet.idsMatch(newCellSet, coordinatesForBoth, newRow.getOrdinal())) { + log.debug("primary keys do not match - full refresh"); + return false; + } + } catch (DerivedOlapException e1) { // NOSONAR + log.error(e1.getLocalizedMessage()); + } + } + if ((newRow != null) && (oldRow != null)) { + List<DerivedMember> oldRowMembers = oldRow.getMembers(); + List<DerivedMember> newRowMembers = newRow.getMembers(); + if (oldRowMembers.size() != newRowMembers.size()) { + log.debug("count of row keys do not match - full refresh"); + return false; + } + for (int memberIndex = 0; memberIndex < oldRowMembers.size(); memberIndex++) { + String[] oldTokens = oldRowMembers.get(memberIndex).getUniqueName().split("\\]\\.\\["); + String[] newTokens = newRowMembers.get(memberIndex).getUniqueName().split("\\]\\.\\["); + if (oldTokens.length != newTokens.length) { + log.debug("count of row key tokens do not match - full refresh"); + return false; + } + for (int tokenIndex = 1; tokenIndex < oldTokens.length; tokenIndex++) { + if (!oldTokens[tokenIndex].equals(newTokens[tokenIndex])) { + if (!positionMap.containsKey(-1 * tokenIndex)) { + DerivedPosition position = new DerivedPosition(newRow.getMembers(), -1 * tokenIndex, newRow.getContainer()); + addCellSetContainerProperty(position, "", null, true); + } + if (!setCellSetContainerValue(newRow, positionMap.get(-1 * tokenIndex).getPosition(), newTokens[tokenIndex].replace("]", ""))) { + // the container cell differs in type, mostly caused by changing pivot table + // full refresh required + log.debug("column type differs - full refresh"); + return false; + } + } + } + } + } + for (DerivedPosition newColumn : newCellSet.getAxes().get(DerivedAxis.AXIS_COLUMNS).getPositions()) { + coordinatesForBoth.set(DerivedAxis.AXIS_COLUMNS, newColumn.getOrdinal()); + boolean valueFound = true; + Object newValue = null; + Object oldValue = null; + try { + newValue = newCellSet.getCell(coordinatesForBoth).getValue(); + } catch (DerivedOlapException | NullPointerException e1) { // NOSONAR + log.error(e1.getLocalizedMessage()); + } + if (rowFound) { + try { + oldValue = cellSet.getCell(coordinatesForBoth).getValue(); + } catch (DerivedOlapException | NullPointerException e) { // NOSONAR + valueFound = false; + } + } else { + valueFound = false; + } + boolean valueChanged = objectChanged(newValue, oldValue); + boolean exactlyOneValueGiven = oldValue == null && newValue != null || oldValue != null && newValue == null; + if (valueChanged && rowFound && exactlyOneValueGiven) { + return false; + } + if (newRow != null && getContainerProperty(newRow.getOrdinal(), newColumn.getOrdinal()) == null) { + rowFound = false; + valueFound = false; + } + if (!rowFound) { + createRow(newRow); + } + + if (newRow == null) { + log.error("newRow == null"); + return false; + } + + if (!valueFound && newValue != null && getContainerProperty(newRow.getOrdinal(), newColumn.getOrdinal()) == null) { + addCellSetContainerProperty(newColumn, newValue, null, false); + } + + if ((!valueFound || valueChanged) && (newValue != null) && !setCellSetContainerValue(newRow, newColumn, newValue)) { + // the container cell differs in type, mostly caused by changing pivot table + // full refresh required + log.debug("column type differs - full refresh"); + return false; + } + } + } + // delete remaining old rows if new cellset has less rows + while (oldIterator.hasNext()) { + DerivedPosition row = oldIterator.next(); + removeItem(row.getOrdinal()); + } + cellSet = newCellSet; + return true; + } + + public void fillContainer() { + for (DerivedPosition row : cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositions()) { + createRow(row); + for (DerivedPosition column : cellSet.getAxes().get(DerivedAxis.AXIS_COLUMNS).getPositions()) { + createColumn(row, column); + } + } + } + + public List<Integer> getCoordinateSystem() { + return coordinateSystem; + } + + @SuppressWarnings("serial") + public void addExtras(FilterTable table) { + // add format converter + for (Object propertyId : getContainerPropertyIds()) { + DerivedPosition column = getColumnPosition((Integer) propertyId); + if (column != null) { + PropertyLookup lookup = findColumnProperty(column); + if (lookup != null) { + // add converters + if (lookup.getFormat() != null) { + switch (lookup.getType()) { + case PropertyLookup.DATE: + table.setConverter(column.getOrdinal(), lookup.getDateConverter()); + break; + case PropertyLookup.NUMBER: + table.setConverter(column.getOrdinal(), lookup.getNumberConverter()); + break; + case PropertyLookup.BIGDECIMAL: + table.setConverter(column.getOrdinal(), lookup.getBigDecimalConverter()); + break; + case PropertyLookup.STRING: + break; + } + } + // collapse column if applied + table.setColumnCollapsed(column.getOrdinal(), lookup.isCollapseColumn()); + // disable filter if of type cellsetimage + if (positionMap.containsKey(column.getOrdinal()) + && (positionMap.get(column.getOrdinal()).getType() == CellSetImage.class || positionMap.get(column.getOrdinal()).getType() == BlobUploadComponent.class)) { + table.setFilterFieldVisible(column.getOrdinal(), false); + // table.setColumnExpandRatio(column.getOrdinal(), 1.0f); + } + // add column icons + if (lookup.getColumnIcon() != null) { + table.setColumnIcon(column.getOrdinal(), lookup.getColumnIcon()); + } + } + } + } + + // add style generator + table.setCellStyleGenerator(new CustomTable.CellStyleGenerator() { + @Override + public String getStyle(CustomTable source, Object itemId, Object propertyId) { + + if (source == null) + return null; + + CellSetIndexedContainer container = (source instanceof PagedFilterTable) ? (CellSetIndexedContainer) ((PagedFilterTable<?>) source).getContainerDataSource() + .getContainer() : (CellSetIndexedContainer) source.getContainerDataSource(); + if (container == null) + return null; + + if (propertyId == null && itemId != null) { + // a row style is requested + return container.getRowStyle(); + } + + if (propertyId == null || itemId == null) + return null; + + DerivedPosition column = getColumnPosition((Integer) propertyId); + DerivedPosition row = cellSet.getAxes().get(1).getPositionByOrdinal((Integer) itemId); + if (column == null || row == null) + return null; + + PropertyLookup lookup = container.findColumnProperty(column); + if (lookup == null) + return null; + + String defaultStyle = lookup.getDefaultStyle(); + List<Integer> coordinates = new ArrayList<>(getCoordinateSystem()); + if (column.getOrdinal() >= 0 && row.getOrdinal() >= 0) { + coordinates.set(0, column.getOrdinal()); + coordinates.set(1, row.getOrdinal()); + Object value = null; + try { + value = cellSet.getCell(coordinates).getValue(); + if (value != null) { + String style = lookup.getValueStyle(value, (int) itemId); + // for odd rows use the darker -odd style as background-color + if (((int) itemId) % 2 != 0) { + style += "-odd"; + } + + if (style != null && style.length() > 0) { + log.debug("style for row:" + row.toUnformattedString() + " col:" + column.toUnformattedString() + " " + style + " " + defaultStyle); + return style + " " + defaultStyle; + } + } + } catch (DerivedOlapException | NullPointerException e) { // NOSONAR + log.error(e.getLocalizedMessage()); + } + } + // for odd rows use the darker -odd style as background-color + if (((int) itemId) % 2 != 0 && defaultStyle != null && defaultStyle.endsWith("rowheader")) { + defaultStyle += "-odd"; + } + log.debug("default style for row:" + row.toUnformattedString() + " col:" + column.toUnformattedString() + " " + defaultStyle); + return defaultStyle; + } + }); + + // add tooltips + table.setItemDescriptionGenerator(new AbstractSelect.ItemDescriptionGenerator() { + @Override + public String generateDescription(Component source, Object itemId, Object propertyId) { + + if (source == null) + return null; + + CellSetIndexedContainer container = (source instanceof PagedFilterTable) ? (CellSetIndexedContainer) ((PagedFilterTable<?>) ((AbstractSelect) source)) + .getContainerDataSource().getContainer() : (CellSetIndexedContainer) ((AbstractSelect) source).getContainerDataSource(); + + if (container == null) + return null; + + if (propertyId == null || itemId == null) + return null; + + DerivedPosition column = getColumnPosition((Integer) propertyId); + DerivedPosition row = cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositionByOrdinal((Integer) itemId); + if (column == null || row == null) + return null; + + PropertyLookup lookup = container.findColumnProperty(column); + if (lookup == null) + return null; + + List<Integer> coordinates = new ArrayList<>(getCoordinateSystem()); + if (column.getOrdinal() >= 0 && row.getOrdinal() >= 0) { + coordinates.set(DerivedAxis.AXIS_COLUMNS, column.getOrdinal()); + coordinates.set(DerivedAxis.AXIS_ROWS, row.getOrdinal()); + Object value = null; + try { + value = cellSet.getCell(coordinates).getValue(); + if (value != null) { + return lookup.getValueTooltip(value); + } + } catch (DerivedOlapException | NullPointerException e) { // NOSONAR + log.error(e.getLocalizedMessage()); + } + } else if (column.getOrdinal() < 0 && row.getOrdinal() >= 0) { + Object value = null; + try { + value = getOrdinalCellValue(row.getOrdinal(), column.toUppercaseString()); + if (value != null) { // NOSONAR + return lookup.getValueTooltip(value); + } + } catch (DerivedOlapException | NullPointerException e) { // NOSONAR + log.error(e.getLocalizedMessage()); + } + } else { + return row.toUnformattedString(); + // NOSONAR return lookupMap.get(column.toUppercaseString()).getDefaultStyle(); + } + return null; + } + }); + } + + public String getStringValueByOrdinal(int itemId, int ordinal) { + String value = null; + DerivedCell cell = getCell(itemId, null, ordinal); + if (cell != null) { + value = cell.getFormattedValue(); + } + return value; + } + + public String getStringValueByAggregate(int itemId) { + return getCellTitle(itemId, null); + } + + public String getStringValueByProperty(int itemId, String columnName) { + String value = getCellTitle(itemId, columnName); + if (value == null) { + DerivedCell cell = getCell(itemId, columnName, null); + if (cell != null) { + value = cell.getFormattedValue(); + } + } + return value; + } + + public long getTaskId(int itemId) { + DerivedCell cell = getCell(itemId, "taskid", null); + if (cell != null) { + Object value = cell.getValue(); + if (value.getClass().equals(Long.class)) { + return (long) value; + } + } + return -1; + } + + public String getProcessId(int itemId) { + DerivedCell cell = getCell(itemId, "processid", null); + if (cell != null) { + Object value = cell.getValue(); + if (value.getClass().equals(String.class)) { + return (String) value; + } + } + return null; + } + + public String getTaskName(int itemId) { + DerivedCell cell = getCell(itemId, "name", null); + if (cell != null) { + Object value = cell.getValue(); + if (value.getClass().equals(String.class)) { + return (String) value; + } + } + return null; + } + + public String getCellTitle(int itemId, String columnName) { + String fullTitle = ""; + List<Integer> coordinate = new ArrayList<>(getCoordinateSystem()); + DerivedPosition rows = cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositionByOrdinal(itemId); + if (rows != null) { + coordinate.set(DerivedAxis.AXIS_ROWS, rows.getOrdinal()); + for (DerivedMember member : rows.getMembers()) { + String[] tokens = member.getUniqueName().split("\\]\\.\\["); + for (int token = 0; token < tokens.length; token++) { + String colName = tokens[token].replace("]", "").replace("[", "").toLowerCase(); + if (columnName != null) { + if (colName.equals(columnName)) { + return tokens[token + 1].replace("]", "").replace("[", ""); + } + } else if (token > 0) { // full title without the first hierarchy as it is redundant + if (fullTitle.length() > 0) { + fullTitle += " "; + } + fullTitle += tokens[token].replace("]", "").replace("[", ""); + } + } + } + } + if (columnName != null) { + return null; + } else { + return fullTitle; + } + } + + public DerivedCell getCell(int itemId, String columnName, Integer ordinal) { + List<Integer> coordinate = new ArrayList<>(getCoordinateSystem()); + DerivedPosition rows = cellSet.getAxes().get(DerivedAxis.AXIS_ROWS).getPositionByOrdinal(itemId); + if (rows != null) { + coordinate.set(DerivedAxis.AXIS_ROWS, rows.getOrdinal()); + for (DerivedPosition columns : cellSet.getAxes().get(0).getPositions()) { + if (ordinal != null) { + if (columns.getOrdinal() == ordinal) { + coordinate.set(DerivedAxis.AXIS_COLUMNS, columns.getOrdinal()); + try { + return cellSet.getCell(coordinate); + } catch (DerivedOlapException e) { // NOSONAR + log.error(e.getLocalizedMessage()); + } + break; + } + } else { + for (DerivedMember colmember : columns.getMembers()) { + String colName = colmember.getCaption().toLowerCase(); + if (colName.equals(columnName)) { + coordinate.set(DerivedAxis.AXIS_COLUMNS, columns.getOrdinal()); + try { + return cellSet.getCell(coordinate); + } catch (DerivedOlapException | NullPointerException e) { // NOSONAR + log.error(e.getLocalizedMessage()); + } + } + } + } + } + } + return null; + } + + public void setSort(Object source, String columnName, boolean ascending) { + for (DerivedPosition columns : cellSet.getAxes().get(DerivedAxis.AXIS_COLUMNS).getPositions()) { + if (columns.toUppercaseString().equals(columnName)) { + if (source instanceof PagedFilterTable) { + ((PagedFilterTable<?>) source).setSortContainerPropertyId(columns.getOrdinal()); + if (ascending != ((PagedFilterTable<?>) source).isSortAscending()) { + ((PagedFilterTable<?>) source).setSortAscending(ascending); + } + } else { + ((FilterTable) source).setSortContainerPropertyId(columns.getOrdinal()); + if (ascending != ((FilterTable) source).isSortAscending()) { + ((FilterTable) source).setSortAscending(ascending); + } + } + break; + } + } + + } + + public void registerSelection(Map<String, Object> map, Object itemId) { + if (itemId == null) { + // reset selectedValues + for (int positionId : positionMap.keySet()) { + PositionInfo pos = positionMap.get(positionId); + pos.setSelectedValue(null); + } + return; + } + if (itemId instanceof Integer) { + for (int positionId : positionMap.keySet()) { + PositionInfo pos = positionMap.get(positionId); + String value = getCellTitle((int) itemId, pos.getPosition().toUnformattedString()); + if (value != null) { + pos.setSelectedValue(value); + } else { + DerivedCell cell = getCell((int) itemId, null, positionId); + if (cell != null) { + pos.setSelectedValue(cell.getValue()); + } else { + pos.setSelectedValue(null); + } + } + } + } + map.put("tablePositionInfo", positionMap); + } + + public Locale getLocale() { + return locale; + } + + public void setLocale(Locale locale) { + this.locale = locale; + for (String lookup : propertyLookupMap.keySet()) { + propertyLookupMap.get(lookup).setLocale(locale); + } + this.fireContainerPropertySetChange(); + } +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterControlConfig.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterControlConfig.java new file mode 100644 index 0000000..cf6e213 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterControlConfig.java @@ -0,0 +1,48 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import java.beans.PropertyChangeListener; +import java.beans.PropertyChangeSupport; + +import org.tepi.filtertable.paged.PagedFilterControlConfig; + +public class CellSetPagedFilterControlConfig extends PagedFilterControlConfig { + private PropertyChangeSupport pcs = new PropertyChangeSupport(this); + + public void addPropertyChangeListener(final PropertyChangeListener listener) { + this.pcs.addPropertyChangeListener(listener); + } + + public void removePropertyChangeListener(final PropertyChangeListener listener) { + this.pcs.removePropertyChangeListener(listener); + } + + public String getItemsPerPage() { + return super.getItemsPerPage(); + } + + public void setItemsPerPage(String itemsPerPage) { + super.setItemsPerPage(itemsPerPage); + } + + public String getPage() { + return super.getPage(); + } + + public void setPage(String page) { + super.setPage(page); + } + +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterTable.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterTable.java new file mode 100644 index 0000000..88d2390 --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CellSetPagedFilterTable.java @@ -0,0 +1,280 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import java.text.NumberFormat; +import java.util.Locale; + +import org.eclipse.core.databinding.DataBindingContext; +import org.eclipse.core.databinding.UpdateValueStrategy; +import org.eclipse.core.databinding.beans.BeansObservables; +import org.eclipse.osbp.runtime.common.i18n.ITranslator; +import org.eclipse.osbp.runtime.web.vaadin.databinding.VaadinObservables; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedPosition; +import org.tepi.filtertable.paged.PagedFilterControlConfig; +import org.tepi.filtertable.paged.PagedFilterTable; +import org.tepi.filtertable.paged.PagedTableChangeEvent; + +import com.vaadin.data.util.converter.StringToIntegerConverter; +import com.vaadin.shared.ui.label.ContentMode; +import com.vaadin.ui.AbstractOrderedLayout; +import com.vaadin.ui.Alignment; +import com.vaadin.ui.Button; +import com.vaadin.ui.Button.ClickEvent; +import com.vaadin.ui.Button.ClickListener; +import com.vaadin.ui.ComboBox; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; +import com.vaadin.ui.TextField; +import com.vaadin.ui.UI; +import com.vaadin.ui.themes.Reindeer; + +@SuppressWarnings({ "serial", "rawtypes" }) +public class CellSetPagedFilterTable extends PagedFilterTable { + private HorizontalLayout controlBar = null; + private AbstractOrderedLayout parent = null; + private ITranslator translator = null; + private DataBindingContext dbc = null; + + @Override + public String getColumnHeader(Object propertyId) { + if (getColumnHeaderMode() == ColumnHeaderMode.HIDDEN) { + return null; + } + DerivedPosition column = ((CellSetIndexedContainer)getContainerDataSource().getContainer()).getColumnPosition(propertyId); + if (column != null) { + return column.toString(); + } + return propertyId.toString(); + } + + + @Override + public void setLocale(Locale locale) { + super.setLocale(locale); + addControls(parent, translator, dbc); + resetFilters(); + } + + public void addControls(AbstractOrderedLayout parent, ITranslator translator, DataBindingContext dbc) { + this.parent = parent; + this.translator = translator; + this.dbc = dbc; + if (controlBar != null) { + parent.removeComponent(controlBar); + controlBar = null; + } + PagedFilterControlConfig config = new PagedFilterControlConfig(); + Label itemsPerPageLabel = new Label(); + dbc.bindValue(VaadinObservables.observeDescription(itemsPerPageLabel), + BeansObservables.observeValue(translator, "items_per_page"), + new UpdateValueStrategy(UpdateValueStrategy.POLICY_NEVER), new UpdateValueStrategy(UpdateValueStrategy.POLICY_UPDATE)); + + itemsPerPageLabel.setSizeUndefined(); + final ComboBox itemsPerPageSelect = new ComboBox(); + + for (Integer i : config.getPageLengths()) { + itemsPerPageSelect.addItem(i); + itemsPerPageSelect.setItemCaption(i, String.valueOf(i)); + } + itemsPerPageSelect.setImmediate(true); + itemsPerPageSelect.setNullSelectionAllowed(false); + itemsPerPageSelect.setWidth(null); + itemsPerPageSelect.addValueChangeListener(new ValueChangeListener() { + private static final long serialVersionUID = -2255853716069800092L; + + @Override + public void valueChange( + com.vaadin.data.Property.ValueChangeEvent event) { + setPageLength((Integer) event.getProperty().getValue()); + } + }); + if (itemsPerPageSelect.containsId(getPageLength())) { + itemsPerPageSelect.select(getPageLength()); + } else { + itemsPerPageSelect.select(itemsPerPageSelect.getItemIds() + .iterator().next()); + } + Label pageLabel = new Label(); + dbc.bindValue(VaadinObservables.observeDescription(itemsPerPageLabel), + BeansObservables.observeValue(translator, "page"), + new UpdateValueStrategy(UpdateValueStrategy.POLICY_NEVER), new UpdateValueStrategy(UpdateValueStrategy.POLICY_UPDATE)); + + final TextField currentPageTextField = new TextField(); + currentPageTextField.setValue(String.valueOf(getCurrentPage())); + currentPageTextField.setConverter(new StringToIntegerConverter() { + @Override + protected NumberFormat getFormat(Locale locale) { + NumberFormat result = super.getFormat(UI.getCurrent() + .getLocale()); + result.setGroupingUsed(false); + return result; + } + }); + Label separatorLabel = new Label(" / ", ContentMode.HTML); + final Label totalPagesLabel = new Label( + String.valueOf(getTotalAmountOfPages()), ContentMode.HTML); + currentPageTextField.setStyleName(Reindeer.TEXTFIELD_SMALL); + currentPageTextField.setImmediate(true); + currentPageTextField.addValueChangeListener(new ValueChangeListener() { + private static final long serialVersionUID = -2255853716069800092L; + + @Override + public void valueChange( + com.vaadin.data.Property.ValueChangeEvent event) { + if (currentPageTextField.isValid() + && currentPageTextField.getValue() != null) { + int page = Integer.valueOf(String + .valueOf(currentPageTextField.getValue())); + setCurrentPage(page); + } + } + }); + pageLabel.setWidth(null); + currentPageTextField.setColumns(3); + separatorLabel.setWidth(null); + totalPagesLabel.setWidth(null); + + controlBar = new HorizontalLayout(); + HorizontalLayout pageSize = new HorizontalLayout(); + HorizontalLayout pageManagement = new HorizontalLayout(); + final Button first = new Button(config.getFirst(), new ClickListener() { + private static final long serialVersionUID = -355520120491283992L; + + @Override + public void buttonClick(ClickEvent event) { + setCurrentPage(0); + } + }); + final Button previous = new Button(config.getPrevious(), + new ClickListener() { + private static final long serialVersionUID = -355520120491283992L; + + @Override + public void buttonClick(ClickEvent event) { + previousPage(); + } + }); + final Button next = new Button(config.getNext(), new ClickListener() { + private static final long serialVersionUID = -1927138212640638452L; + + @Override + public void buttonClick(ClickEvent event) { + nextPage(); + } + }); + final Button last = new Button(config.getLast(), new ClickListener() { + private static final long serialVersionUID = -355520120491283992L; + + @Override + public void buttonClick(ClickEvent event) { + setCurrentPage(getTotalAmountOfPages()); + } + }); + first.setStyleName(Reindeer.BUTTON_LINK); + previous.setStyleName(Reindeer.BUTTON_LINK); + next.setStyleName(Reindeer.BUTTON_LINK); + last.setStyleName(Reindeer.BUTTON_LINK); + + itemsPerPageLabel.addStyleName("pagedtable-itemsperpagecaption"); + itemsPerPageSelect.addStyleName("pagedtable-itemsperpagecombobox"); + pageLabel.addStyleName("pagedtable-pagecaption"); + currentPageTextField.addStyleName("pagedtable-pagefield"); + separatorLabel.addStyleName("pagedtable-separator"); + totalPagesLabel.addStyleName("pagedtable-total"); + first.addStyleName("pagedtable-first"); + previous.addStyleName("pagedtable-previous"); + next.addStyleName("pagedtable-next"); + last.addStyleName("pagedtable-last"); + + itemsPerPageLabel.addStyleName("pagedtable-label"); + itemsPerPageSelect.addStyleName("pagedtable-combobox"); + pageLabel.addStyleName("pagedtable-label"); + currentPageTextField.addStyleName("pagedtable-label"); + separatorLabel.addStyleName("pagedtable-label"); + totalPagesLabel.addStyleName("pagedtable-label"); + first.addStyleName("pagedtable-button"); + previous.addStyleName("pagedtable-button"); + next.addStyleName("pagedtable-button"); + last.addStyleName("pagedtable-button"); + + pageSize.addComponent(itemsPerPageLabel); + pageSize.addComponent(itemsPerPageSelect); + pageSize.setComponentAlignment(itemsPerPageLabel, Alignment.MIDDLE_LEFT); + pageSize.setComponentAlignment(itemsPerPageSelect, + Alignment.MIDDLE_LEFT); + pageSize.setSpacing(true); + pageManagement.addComponent(first); + pageManagement.addComponent(previous); + pageManagement.addComponent(pageLabel); + pageManagement.addComponent(currentPageTextField); + pageManagement.addComponent(separatorLabel); + pageManagement.addComponent(totalPagesLabel); + pageManagement.addComponent(next); + pageManagement.addComponent(last); + pageManagement.setComponentAlignment(first, Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(previous, Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(pageLabel, Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(currentPageTextField, + Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(separatorLabel, + Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(totalPagesLabel, + Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(next, Alignment.MIDDLE_LEFT); + pageManagement.setComponentAlignment(last, Alignment.MIDDLE_LEFT); + pageManagement.setWidth(null); + pageManagement.setSpacing(true); + controlBar.addComponent(pageSize); + controlBar.addComponent(pageManagement); + controlBar.setComponentAlignment(pageManagement, + Alignment.MIDDLE_CENTER); + controlBar.setWidth(100, Unit.PERCENTAGE); + controlBar.setExpandRatio(pageSize, 1); + + if (super.getContainerDataSource() != null) { + first.setEnabled(super.getContainerDataSource().getStartIndex() > 0); + previous.setEnabled(super.getContainerDataSource().getStartIndex() > 0); + next.setEnabled(super.getContainerDataSource().getStartIndex() < super.getContainerDataSource().getRealSize() + - getPageLength()); + last.setEnabled(super.getContainerDataSource().getStartIndex() < super.getContainerDataSource().getRealSize() + - getPageLength()); + } + + addListener(new PageChangeListener() { + private boolean inMiddleOfValueChange; + + @Override + public void pageChanged(PagedTableChangeEvent event) { + if (!inMiddleOfValueChange) { + inMiddleOfValueChange = true; + first.setEnabled(event.getTable().getContainerDataSource().getStartIndex() > 0); + previous.setEnabled(event.getTable().getContainerDataSource().getStartIndex() > 0); + next.setEnabled(event.getTable().getContainerDataSource().getStartIndex() < event.getTable().getContainerDataSource() + .getRealSize() - getPageLength()); + last.setEnabled(event.getTable().getContainerDataSource().getStartIndex() < event.getTable().getContainerDataSource() + .getRealSize() - getPageLength()); + currentPageTextField.setValue(String + .valueOf(getCurrentPage())); + totalPagesLabel.setValue(Integer + .toString(getTotalAmountOfPages())); + itemsPerPageSelect + .setValue(getPageLength()); + inMiddleOfValueChange = false; + } + } + }); + parent.addComponent(controlBar); + } +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CheckboxSelectionCellSetFilterTable.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CheckboxSelectionCellSetFilterTable.java new file mode 100644 index 0000000..ed6429d --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/CheckboxSelectionCellSetFilterTable.java @@ -0,0 +1,322 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ +package org.eclipse.osbp.xtext.table.common; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; +import java.util.Set; +import java.util.TreeSet; + +import com.vaadin.data.Container; +import com.vaadin.data.Property; +import com.vaadin.ui.AbstractSelect; +import com.vaadin.ui.CheckBox; +import com.vaadin.ui.Component; +import com.vaadin.ui.CustomTable; +import com.vaadin.ui.TextField; + +public class CheckboxSelectionCellSetFilterTable extends CellSetFilterTable { + + public enum UserSelectionState { + SINGLE { + @Override + protected String headerString() { return ""; } + @Override + protected UserSelectionState nextState() { return SINGLE; } + }, + NONE { + @Override + protected String headerString() { return "[X]"; } + @Override + protected UserSelectionState nextState() { return ALL; } + }, + SOME { + @Override + protected String headerString() { return "[X]"; } + @Override + protected UserSelectionState nextState() { return ALL; } + }, + ALL { + @Override + protected String headerString() { return "[-]"; } + @Override + protected UserSelectionState nextState() { return NONE; } + }; + + abstract protected String headerString(); + abstract protected UserSelectionState nextState(); + } + + private static final long serialVersionUID = -5042607921306226333L; + + private static final Object CHECKBOX_COLUMN_ID = new Integer(-99999); + private static final int CHECKBOX_COLUMN_WIDTH = 64; + + /** + * This map keeps track of all the created and attached checkboxes, by ItemId + */ + protected Map<Object, CheckBox> itemIdToCheckbox = new HashMap<Object, CheckBox>(); + /** + * This is the last selection value of the table. We need to keep track of what *was* selected, + * so that we can "deselect" the checkboxes. + */ + private Object lastSelectionValue; + private UserSelectionState userSelectionState = UserSelectionState.SOME; + /** + * A simple flag to stop a circular event + */ + private boolean ignorePropertyChangeEventInCheckBoxListener; + + @SuppressWarnings("deprecation") + public CheckboxSelectionCellSetFilterTable() { + super(); + + addGeneratedColumn(CHECKBOX_COLUMN_ID, new ColumnGenerator() { + private static final long serialVersionUID = -1241374338743135797L; + + @Override + public Object generateCell(final CustomTable source, final Object itemId, Object columnId) { + final boolean selected = isItemIdSelected(source, itemId); + final CheckBox checkBox = new CheckBox("", selected); + checkBox.addValueChangeListener(new Property.ValueChangeListener() { + private static final long serialVersionUID = -7317483363411043081L; + + @Override + public void valueChange(Property.ValueChangeEvent valueChangeEvent) { + // Don't react to the event if we're being changed from the table-value-change event + if (!ignorePropertyChangeEventInCheckBoxListener) { + Boolean selected = (Boolean) valueChangeEvent.getProperty().getValue(); + if (selected) { + source.select(itemId); + } + else { + source.unselect(itemId); + } + setUserSelectionState(UserSelectionState.SOME); + } + } + }); + if (selected) { + source.select(itemId); + itemIdToCheckbox.put(itemId, checkBox); + } + + // Let's keep track of the checkboxes + checkBox.addAttachListener(new AttachListener() { + private static final long serialVersionUID = 2477921773100973217L; + + @Override + public void attach(AttachEvent event) { + itemIdToCheckbox.put(itemId, checkBox); + } + }); + checkBox.addDetachListener(new DetachListener() { + private static final long serialVersionUID = -2093323551404903130L; + + @Override + public void detach(DetachEvent event) { + itemIdToCheckbox.remove(itemId); + } + }); + checkBox.setWidth(CHECKBOX_COLUMN_WIDTH+"px"); + return checkBox; + } + }); + setFilterFieldVisible(CHECKBOX_COLUMN_ID, true); + + addListener(new HeaderClickListener() { + private static final long serialVersionUID = 1238308428039209109L; + + @Override + public void headerClick(HeaderClickEvent event) { + if (CHECKBOX_COLUMN_ID.equals(event.getPropertyId())) { + setUserSelectionState(userSelectionState.nextState()); + } + } + }); + //setColumnHeader(CHECKBOX_COLUMN_ID, userSelectionState.headerString()); + setUserSelectionState(UserSelectionState.SOME); + + this.lastSelectionValue = getValue(); + this.ignorePropertyChangeEventInCheckBoxListener = false; + + /* + * When the table value - i.e. the selection - changes, make sure + * any attached checkboxes are updated + */ + addValueChangeListener(new Property.ValueChangeListener() { + private static final long serialVersionUID = 6017328233818014479L; + + @Override + public void valueChange(Property.ValueChangeEvent event) { + ignorePropertyChangeEventInCheckBoxListener = true; + Object newSelectionValue = event.getProperty().getValue(); + /* Deselect all of the old checkboxes, then reselect all of the new ones. + If we wanted to be really smart, you could work out which checkboxes you wanted to change. + I don't care about being smart right now */ + setCheckBoxes(lastSelectionValue, false); + setCheckBoxes(newSelectionValue, true); + + lastSelectionValue = newSelectionValue; + ignorePropertyChangeEventInCheckBoxListener = false; + } + }); + try { + setColumnWidth(CHECKBOX_COLUMN_ID, CHECKBOX_COLUMN_WIDTH); + } + catch (Exception e) {} + } + + @Override + public void setMultiSelect(boolean multiSelect) { + if (multiSelect) { + setUserSelectionState(UserSelectionState.SOME); + } + else { + setUserSelectionState(UserSelectionState.SINGLE); + } + super.setMultiSelect(multiSelect); + } + + private void setUserSelectionState(UserSelectionState nextState) { + switch (nextState) { + case NONE: + setCheckBoxes(itemIdToCheckbox.keySet(), false); + break; + case ALL: + setCheckBoxes(itemIdToCheckbox.keySet(), true); + break; + case SOME: + break; + case SINGLE: + break; + } + userSelectionState = nextState; + setColumnHeader(CHECKBOX_COLUMN_ID, userSelectionState.headerString()); + } + + @Override + public void setContainerDataSource(Container newDataSource, Collection<?> visibleIds) { + // force selection column to be the first + if ((visibleIds.size() > 1) && (visibleIds.iterator().next() instanceof Integer)) { + Set<Integer> sortedVisibleIds = new TreeSet<Integer>(); + for (Object item : visibleIds) { + sortedVisibleIds.add((Integer) item); + } + visibleIds = sortedVisibleIds; + } + super.setContainerDataSource(newDataSource, visibleIds); + try { + setColumnWidth(CHECKBOX_COLUMN_ID, CHECKBOX_COLUMN_WIDTH); + } + catch (Exception e) {} + updateCheckboxColumnFilterLabel(); + } + + protected void updateCheckboxColumnFilterLabel() { + Map<Object, Component> columnIdToFilterMap = getColumnIdToFilterMap(); + Component c = null; + if (columnIdToFilterMap != null) { + c = columnIdToFilterMap.get(CHECKBOX_COLUMN_ID); + } + if (c instanceof TextField) { + String caption = ""; + if (getContainerDataSource() instanceof CellSetIndexedContainer) { + CellSetIndexedContainer dataSource = (CellSetIndexedContainer) getContainerDataSource(); + int allItems = dataSource.getAllItemIds().size(); + //int filteredItems = dataSource.getFilteredItemIds() == null ? 0 : dataSource.getFilteredItemIds().size(); + int selected = 0; + Object value = getValue(); + if (value instanceof Collection) { + selected = ((Collection) value).size(); + } + else if (value != null) { + selected = 1; + } + caption = selected+"/"+allItems; + } + ((TextField) c).setInputPrompt(caption); + c.setEnabled(false); + setFilterFieldVisible(CHECKBOX_COLUMN_ID, true); + } + } + + /** + * Set the value of all of the checkboxes + * @param itemIdOrIds + * @param value + */ + private void setCheckBoxes(Object itemIdOrIds, boolean value) { + if (itemIdOrIds instanceof Collection) { + Collection ids = (Collection) itemIdOrIds; + for (Object id : ids) { + setCheckBox(id, value); + } + } + else { + setCheckBox(itemIdOrIds, value); + } + } + + /** + * Set the value of the given checkbox + * @param id + * @param value + */ + public void setCheckBox(Object id, boolean value) { + CheckBox checkBox = itemIdToCheckbox.get(id); + if (checkBox != null) { + checkBox.setValue(value); + updateCheckboxColumnFilterLabel(); + } + } + + /** + * Is the given itemId selected ? + * @param select + * @param itemId + * @return + */ + protected boolean isItemIdSelected(AbstractSelect select, Object itemId) { + switch (userSelectionState) { + case NONE: + return false; + case ALL: + return true; + case SOME: + case SINGLE: + Object value = select.getValue(); + if (itemId == null || value == null) { + return false; + } + if (select.isMultiSelect()) { + return ((Collection) value).contains(itemId); + } + return itemId.equals(value); + } + return false; + } + + @Override + public String getColumnHeader(Object propertyId) { + if (getColumnHeaderMode() == ColumnHeaderMode.HIDDEN) { + return null; + } + if (propertyId == CHECKBOX_COLUMN_ID) { + return userSelectionState.headerString(); + } + return super.getColumnHeader(propertyId); + } +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/PositionInfo.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/PositionInfo.java new file mode 100644 index 0000000..b5ff30d --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/PositionInfo.java @@ -0,0 +1,62 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedPosition; + +import org.eclipse.osbp.utils.vaadin.CellSetImage; + +public class PositionInfo { + private DerivedPosition position; + private Class<?> type; + private Class<?> innerType; + private Object selectedValue; + + public DerivedPosition getPosition() { + return position; + } + + public Class<?> getType() { + return type; + } + + public Class<?> getInnerType() { + return innerType; + } + + public Object getSelectedValue() { + return selectedValue; + } + + public void setSelectedValue(Object selectedValue) { + this.selectedValue = selectedValue; + } + + public PositionInfo(DerivedPosition position, Object cellObject) { + this.position = position; + if (cellObject != null) { + type = cellObject.getClass(); + if (type == CellSetImage.class) { + if (((CellSetImage)cellObject).getValue() != null) { + innerType = ((CellSetImage)cellObject).getValue().getClass(); + } + } + else + { + innerType = type; + } + } + } +} + diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/ScorecardCellGenerator.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/ScorecardCellGenerator.java new file mode 100644 index 0000000..64b266d --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/ScorecardCellGenerator.java @@ -0,0 +1,450 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ +package org.eclipse.osbp.xtext.table.common; + +import java.math.BigDecimal; +import java.text.DateFormat; +import java.text.DecimalFormat; +import java.text.DecimalFormatSymbols; +import java.util.Comparator; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Locale; +import java.util.Map; +import java.util.TreeMap; + +import org.eclipse.osbp.ui.api.datamart.DerivedOlapException; +import org.eclipse.osbp.ui.api.themes.IThemeResourceService; +import org.eclipse.osbp.ui.api.themes.IThemeResourceService.ThemeResourceType; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedCellSet; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedMember; +import org.eclipse.osbp.xtext.datamart.common.olap.DerivedPosition; +import org.tepi.filtertable.FilterTable; + +import com.vaadin.server.Resource; +import com.vaadin.ui.CustomTable; +import com.vaadin.ui.Embedded; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; +import com.vaadin.ui.Notification; + +class DbleComparator implements Comparator<Double> { + @Override + public int compare(Double arg0, Double arg1) { + return arg0.compareTo(arg1); + } +} + +class DteComparator implements Comparator<Date> { + @Override + public int compare(Date o1, Date o2) { + return o1.compareTo(o2); + } +} + +@Deprecated +public class ScorecardCellGenerator implements FilterTable.ColumnGenerator { + private static final long serialVersionUID = -3687322995582002747L; + DerivedCellSet cellSet = null; + DerivedPosition rows = null; + List<Integer> coordinate = null; + String format = null; + DateFormat dateFormat = null; + int memberColumnId = -1; + boolean hideLabel = false; + boolean iconFirst = false; + boolean styleDiscreteValues = false; + boolean resourceDiscreteValues = false; + Map<Date, Resource> dateResourceMap = null; + Map<Date, String> dateStyleMap = null; + Map<Double, Resource> doubleResourceMap = null; + Map<Double, String> doubleStyleMap = null; + Map<String, Resource> stringResourceMap = null; + Map<String, String> stringStyleMap = null; + private Locale locale = new Locale("de", "DE"); + + private final IThemeResourceService themeResourceService; + + public ScorecardCellGenerator(IThemeResourceService themeResourceService, DerivedCellSet cellSet, DerivedPosition rows, List<Integer> coordinate) { + this(themeResourceService, cellSet, rows, coordinate, -1); + } + + public ScorecardCellGenerator(IThemeResourceService themeResourceService, DerivedCellSet cellSet, DerivedPosition rows, List<Integer> coordinate, int memberColumnId) { + this.cellSet = cellSet; + this.rows = rows; + this.coordinate = coordinate; + this.memberColumnId = memberColumnId; + this.themeResourceService = themeResourceService; + } + + /** + * @return the hideLabel + */ + public boolean isHideLabel() { + return hideLabel; + } + + /** + * @param hideLabel + * the hideLabel to set + */ + public void setHideLabel(boolean hideLabel) { + this.hideLabel = hideLabel; + } + + public boolean isIconFirst() { + return iconFirst; + } + + public void setIconFirst(boolean iconFirst) { + this.iconFirst = iconFirst; + } + + public String getFormat() { + return format; + } + + public void setFormat(String format) { + this.format = format; + } + + /** + * @param until + * @param resourceName + */ + public void addResourceInterval(Date until, String resourceName) { + Resource resource = themeResourceService.getThemeResource(resourceName, ThemeResourceType.ICON); + if (dateResourceMap == null) { + dateResourceMap = new TreeMap<Date, Resource>(new DteComparator()); + } + dateResourceMap.put(until, resource); + } + + public void addStyleInterval(Date until, String styleName) { + if (dateStyleMap == null) { + dateStyleMap = new TreeMap<Date, String>(new DteComparator()); + } + dateStyleMap.put(until, styleName); + } + + public void addResourceLookup(Date value, String resourceName) { + resourceDiscreteValues = true; + addResourceInterval(value, resourceName); + } + + public void addStyleLookup(Date value, String styleName) { + styleDiscreteValues = true; + addResourceInterval(value, styleName); + } + + public void addResourceLookup(String value, String resourceName) { + Resource resource = themeResourceService.getThemeResource(resourceName, ThemeResourceType.ICON); + if (stringResourceMap == null) { + stringResourceMap = new HashMap<String, Resource>(); + } + stringResourceMap.put(value, resource); + } + + public void addStyleLookup(String value, String styleName) { + if (stringStyleMap == null) { + stringStyleMap = new HashMap<String, String>(); + } + stringStyleMap.put(value, styleName); + } + + public void addResourceLookup(double value, String resourceName) { + resourceDiscreteValues = true; + addResourceInterval(value, resourceName); + } + + public void addStyleLookup(double value, String styleName) { + styleDiscreteValues = true; + addResourceInterval(value, styleName); + } + + public void addResourceInterval(double until, String resourceName) { + Resource resource = themeResourceService.getThemeResource(resourceName, ThemeResourceType.ICON); + if (doubleResourceMap == null) { + doubleResourceMap = new TreeMap<Double, Resource>(new DbleComparator()); + } + doubleResourceMap.put(until, resource); + } + + public void addStyleInterval(double until, String styleName) { + if (doubleStyleMap == null) { + doubleStyleMap = new TreeMap<Double, String>(new DbleComparator()); + } + doubleStyleMap.put(until, styleName); + } + + protected double getDoubleValue(Object value) throws DerivedOlapException { + if (value instanceof Double) { + return (Double) value; + } else if (value instanceof Float) { + return (Float) value; + } else if (value instanceof Long) { + return (Long) value; + } else if (value instanceof Integer) { + return (Integer) value; + } else if (value instanceof BigDecimal) { + return ((BigDecimal) value).doubleValue(); + } + throw new DerivedOlapException("unsupported type conversion"); + } + + @Override + public Object generateCell(CustomTable source, Object itemId, Object columnId) { + Object val = null; + String alignment = ""; + coordinate.set(0, rows.getOrdinal()); + coordinate.set(1, ((DerivedPosition) itemId).getOrdinal()); + try { + // when generating a cell from axis columns, memberColId is -1 + if (memberColumnId == -1) { + val = cellSet.getCell(coordinate).getValue(); + } else { + // when generating a cell from axis rows, memberColId is an index in the qualified member name of the cellSet + for (DerivedMember member : ((DerivedPosition) itemId).getMembers()) { + val = member.getUniqueName().split("\\]\\.\\[")[memberColumnId].replace("]", ""); + break; + } + } + } catch (DerivedOlapException e) { + e.printStackTrace(); + } + if (val == null) { + return null; + } + String caption = null; + if (val instanceof Double || val instanceof Float || val instanceof Long || val instanceof Integer || val instanceof BigDecimal) { + alignment = "v-align-right"; + if (format == null) { + try { + caption = String.format("%f", getDoubleValue(val)); + } catch (DerivedOlapException e) { + e.printStackTrace(); + return null; + } + } else { + DecimalFormat df = null; + try { + df = new DecimalFormat(format, new DecimalFormatSymbols(locale)); + } catch (IllegalArgumentException e) { + String msg = String.format("modeled formatter %s is invalid for decimal numbers: %s", format, e.getLocalizedMessage()); + Notification.show(msg, Notification.Type.ERROR_MESSAGE); + return null; + } + try { + caption = df.format(getDoubleValue(val)); + } catch (DerivedOlapException e) { + e.printStackTrace(); + return null; + } + } + } else if (val instanceof String) { + alignment = "v-align-left"; + if (format == null) { + caption = (String) val; + } else { + caption = String.format(format, (String) val); + } + } else if (val instanceof Date) { + alignment = "v-align-center"; + if (format == null) { + caption = ((Date) val).toString(); + } else { + // SimpleDateFormat df = null; + // try { + // df = new SimpleDateFormat(format, new DateFormatSymbols(locale)); + // } catch (IllegalArgumentException e) { + // String msg = String.format("modeled formatter %s is invalid for date: %s", format, e.getLocalizedMessage()); + // Notification.show(msg, Notification.Type.ERROR_MESSAGE); + // return null; + // } + // caption = df.format((Date)val); + if (format.equals("SHORTDATE")) { + dateFormat = DateFormat.getDateInstance(DateFormat.SHORT, locale); + } + if (format.equals("MEDIUMDATE")) { + dateFormat = DateFormat.getDateInstance(DateFormat.MEDIUM, locale); + } + if (format.equals("LONGDATE")) { + dateFormat = DateFormat.getDateInstance(DateFormat.LONG, locale); + } + if (format.equals("FULLDATE")) { + dateFormat = DateFormat.getDateInstance(DateFormat.FULL, locale); + } + if (format.equals("SHORTTIME")) { + dateFormat = DateFormat.getTimeInstance(DateFormat.SHORT, locale); + } + if (format.equals("MEDIUMTIME")) { + dateFormat = DateFormat.getTimeInstance(DateFormat.MEDIUM, locale); + } + if (format.equals("LONGTIME")) { + dateFormat = DateFormat.getTimeInstance(DateFormat.LONG, locale); + } + if (format.equals("FULLTIME")) { + dateFormat = DateFormat.getTimeInstance(DateFormat.FULL, locale); + } + if (format.equals("SHORTDATESHORTTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT, locale); + } + if (format.equals("SHORTDATEMEDIUMTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.MEDIUM, locale); + } + if (format.equals("SHORTDATELONGTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.LONG, locale); + } + if (format.equals("SHORTDATEFULLTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.FULL, locale); + } + if (format.equals("MEDIUMDATESHORTTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.SHORT, locale); + } + if (format.equals("MEDIUMDATEMEDIUMTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.MEDIUM, locale); + } + if (format.equals("MEDIUMDATELONGTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.LONG, locale); + } + if (format.equals("MEDIUMDATEFULLTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.MEDIUM, DateFormat.FULL, locale); + } + if (format.equals("LONGDATESHORTTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.SHORT, locale); + } + if (format.equals("LONGDATEMEDIUMTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.MEDIUM, locale); + } + if (format.equals("LONGDATELONGTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.LONG, locale); + } + if (format.equals("LONGDATEFULLTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.FULL, locale); + } + if (format.equals("FULLDATESHORTTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.SHORT, locale); + } + if (format.equals("FULLDATEMEDIUMTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.MEDIUM, locale); + } + if (format.equals("FULLDATELONGTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.LONG, locale); + } + if (format.equals("FULLDATEFULLTIME")) { + dateFormat = DateFormat.getDateTimeInstance(DateFormat.FULL, DateFormat.FULL, locale); + } + caption = dateFormat.format((Date) val); + } + } + Label label = new Label(caption); + label.addStyleName(alignment); + if (memberColumnId != -1) { + label.addStyleName("row-header"); + } + if (dateStyleMap != null && val instanceof Date) { + for (Date key : dateStyleMap.keySet()) { + if ((styleDiscreteValues && ((Date) val).equals(key)) || (!styleDiscreteValues && ((Date) val).before(key))) { + label.addStyleName(dateStyleMap.get(key)); + break; + } + } + } + if (doubleStyleMap != null) { + double doubleValue = 0; + try { + doubleValue = getDoubleValue(val); + } catch (DerivedOlapException e) { + e.printStackTrace(); + } + for (Double key : doubleStyleMap.keySet()) { + if ((styleDiscreteValues && doubleValue == key) || (!styleDiscreteValues && doubleValue <= key)) { + label.addStyleName(doubleStyleMap.get(key)); + break; + } + } + } + if (stringStyleMap != null && val instanceof String) { + for (String key : stringStyleMap.keySet()) { + if (key.equals((String) val)) { + label.addStyleName(stringStyleMap.get(key)); + break; + } + } + } + HorizontalLayout hl = null; + Embedded embedded = null; + if (dateResourceMap != null && val instanceof Date) { + hl = new HorizontalLayout(); + embedded = new Embedded(); + for (Date key : dateResourceMap.keySet()) { + if ((resourceDiscreteValues && ((Date) val).equals(key)) || (!resourceDiscreteValues && ((Date) val).before(key))) { + embedded.setSource(dateResourceMap.get(key)); + break; + } + } + } + if (doubleResourceMap != null) { + double doubleValue = 0; + try { + doubleValue = getDoubleValue(val); + } catch (DerivedOlapException e) { + e.printStackTrace(); + } + hl = new HorizontalLayout(); + embedded = new Embedded(); + for (Double key : doubleResourceMap.keySet()) { + if ((resourceDiscreteValues && doubleValue == key) || (!resourceDiscreteValues && doubleValue <= key)) { + embedded.setSource(doubleResourceMap.get(key)); + break; + } + } + } + if (stringResourceMap != null && val instanceof String) { + hl = new HorizontalLayout(); + embedded = new Embedded(); + for (String key : stringResourceMap.keySet()) { + if (key.equals((String) val)) { + embedded.setSource(stringResourceMap.get(key)); + break; + } + } + } + if (hl != null) { + hl.setSizeFull(); + embedded.setWidth("16px"); + if (iconFirst || hideLabel) { + hl.addComponent(embedded); + if (!hideLabel) { + hl.addComponent(label); + hl.setExpandRatio(label, 1.0f); + } else { + hl.setExpandRatio(embedded, 1.0f); + } + } else { + hl.addComponent(label); + hl.addComponent(embedded); + hl.setExpandRatio(label, 1.0f); + } + hl.setSpacing(true); + hl.setPrimaryStyleName("chartsview"); + hl.addStyleName("v-tablecell-combined"); + return hl; + } else { + return label; + } + } + +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterDecorator.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterDecorator.java new file mode 100644 index 0000000..bd81d4c --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterDecorator.java @@ -0,0 +1,210 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import java.io.Serializable; +import java.text.DateFormat; +import java.text.SimpleDateFormat; +import java.util.Locale; + +import org.eclipse.osbp.ui.api.metadata.IDSLMetadataService; +import org.tepi.filtertable.FilterDecorator; +import org.tepi.filtertable.numberfilter.NumberFilterPopupConfig; + +import com.vaadin.server.Resource; +import com.vaadin.shared.ui.datefield.Resolution; + + +@SuppressWarnings("serial") +public class TableFilterDecorator implements FilterDecorator, Serializable { + private String showAll = "show all"; + private String endDate = "end date"; + private String startDate = "start date"; + private String setFilter = "set filter"; + private String clearFilter = "clear filter"; + private String ltPrompt = "lesser than"; + private String gtPrompt = "greater than"; + private String eqPrompt = "equal to"; + private String okCaption = "ok"; + private String resetCaption = "reset"; + private String valueMarker = "[x]"; + + private Locale locale = null; + private int textChangeTimeout = 500; + private NumberFilterPopupConfig conf = new NumberFilterPopupConfig(); + private IDSLMetadataService dslMetadataService; + + public TableFilterDecorator(IDSLMetadataService dslMetadataService) { + this.dslMetadataService = dslMetadataService; + } + + public void setTextChangeTimeout(int textChangeTimeout) { + this.textChangeTimeout = textChangeTimeout; + } + + public void setLocale(Locale locale) { + this.locale = locale; + conf.setEqPrompt(dslMetadataService.translate(locale.toLanguageTag(), eqPrompt)); + conf.setGtPrompt(dslMetadataService.translate(locale.toLanguageTag(), gtPrompt)); + conf.setLtPrompt(dslMetadataService.translate(locale.toLanguageTag(), ltPrompt)); + conf.setOkCaption(dslMetadataService.translate(locale.toLanguageTag(), okCaption)); + conf.setResetCaption(dslMetadataService.translate(locale.toLanguageTag(), resetCaption)); + conf.setValueMarker(dslMetadataService.translate(locale.toLanguageTag(), valueMarker)); + } + + @Override + public String getEnumFilterDisplayName(Object propertyId, Object value) { +// if ("state".equals(propertyId)) { +// State state = (State) value; +// switch (state) { +// case CREATED: +// return "Order has been created"; +// case PROCESSING: +// return "Order is being processed"; +// case PROCESSED: +// return "Order has been processed"; +// case FINISHED: +// return "Order is delivered"; +// } +// } + // returning null will output default value + return null; + } + + + @Override + public Resource getEnumFilterIcon(Object propertyId, Object value) { +// if ("state".equals(propertyId)) { +// State state = (State) value; +// switch (state) { +// case CREATED: +// return new ThemeResource("../runo/icons/16/document.png"); +// case PROCESSING: +// return new ThemeResource("../runo/icons/16/reload.png"); +// case PROCESSED: +// return new ThemeResource("../runo/icons/16/ok.png"); +// case FINISHED: +// return new ThemeResource("../runo/icons/16/globe.png"); +// } +// } + return null; + } + + + @Override + public String getBooleanFilterDisplayName(Object propertyId, boolean value) { +// if ("validated".equals(propertyId)) { +// return value ? "Validated" : "Not validated"; +// } + // returning null will output default value + return null; + } + + + @Override + public Resource getBooleanFilterIcon(Object propertyId, boolean value) { +// if ("validated".equals(propertyId)) { +// return value ? new ThemeResource("../runo/icons/16/ok.png") +// : new ThemeResource("../runo/icons/16/cancel.png"); +// } + return null; + } + + + @Override + public String getFromCaption() { + return dslMetadataService.translate(locale.toLanguageTag(), startDate); + } + + + @Override + public String getToCaption() { + return dslMetadataService.translate(locale.toLanguageTag(), endDate); + } + + + @Override + public String getSetCaption() { + return dslMetadataService.translate(locale.toLanguageTag(), setFilter); + } + + + @Override + public String getClearCaption() { + return dslMetadataService.translate(locale.toLanguageTag(), clearFilter); + } + + + @Override + public boolean isTextFilterImmediate(Object propertyId) { + // use text change events for all the text fields + return true; + } + + + @Override + public int getTextChangeTimeout(Object propertyId) { + // use the same timeout for all the text fields + return textChangeTimeout; + } + + + @Override + public String getAllItemsVisibleString() { + return dslMetadataService.translate(locale.toLanguageTag(), showAll); + } + + + @Override + public Resolution getDateFieldResolution(Object propertyId) { + return Resolution.DAY; + } + + + public DateFormat getDateFormat(Object propertyId) { + if (locale != null) { + return DateFormat.getDateInstance(DateFormat.SHORT, locale); + } + return DateFormat.getDateInstance(DateFormat.SHORT, new Locale("de", "DE")); + } + + + @Override + public boolean usePopupForNumericProperty(Object propertyId) { + return true; + } + + + @Override + public String getDateFormatPattern(Object propertyId) { + if (locale != null) { + DateFormat formatter = DateFormat.getDateInstance(DateFormat.SHORT, locale); + String localPattern = ((SimpleDateFormat)formatter).toPattern(); + return localPattern; + } + return null; + } + + + @Override + public Locale getLocale() { + return locale; + } + + + @Override + public NumberFilterPopupConfig getNumberFilterPopupConfig() { + return conf; + } +} diff --git a/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterGenerator.java b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterGenerator.java new file mode 100644 index 0000000..24341eb --- /dev/null +++ b/org.eclipse.osbp.xtext.table.common/src/org/eclipse/osbp/xtext/table/common/TableFilterGenerator.java @@ -0,0 +1,99 @@ +/** + * + * Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany) + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation + * + */ + package org.eclipse.osbp.xtext.table.common; + +import java.io.Serializable; + +import org.tepi.filtertable.FilterGenerator; + +import com.vaadin.data.Container.Filter; +import com.vaadin.ui.AbstractField; +import com.vaadin.ui.Field; + + +@SuppressWarnings("serial") +public class TableFilterGenerator implements FilterGenerator, Serializable { + + + @Override + public Filter generateFilter(Object propertyId, Object value) { +// if ("id".equals(propertyId)) { +// /* Create an 'equals' filter for the ID field */ +// if (value != null && value instanceof String) { +// try { +// return new Compare.Equal(propertyId, +// Integer.parseInt((String) value)); +// } catch (NumberFormatException ignored) { +// // If no integer was entered, just generate default filter +// } +// } +// } else if ("checked".equals(propertyId)) { +// if (value != null && value instanceof Boolean) { +// if (Boolean.TRUE.equals(value)) { +// return new Compare.Equal(propertyId, value); +// } else { +// return new Or(new Compare.Equal(propertyId, true), +// new Compare.Equal(propertyId, false)); +// } +// } +// } + // For other properties, use the default filter + return null; + } + + + @Override + public Filter generateFilter(Object propertyId, Field<?> originatingField) { + // Use the default filter + return null; + } + + + @Override + public AbstractField<?> getCustomFilterComponent(Object propertyId) { + // removed custom filter component for id +// if ("checked".equals(propertyId)) { +// CheckBox box = new CheckBox(); +// return box; +// } + return null; + } + + + @Override + public void filterRemoved(Object propertyId) { +// Notification n = new Notification("Filter removed from: " + propertyId, +// Notification.Type.TRAY_NOTIFICATION); +// n.setDelayMsec(800); +// n.show(Page.getCurrent()); + } + + + @Override + public void filterAdded(Object propertyId, + Class<? extends Filter> filterType, Object value) { +// Notification n = new Notification("Filter added to: " + propertyId, +// Notification.Type.TRAY_NOTIFICATION); +// n.setDelayMsec(800); +// n.show(Page.getCurrent()); + } + + + @Override + public Filter filterGeneratorFailed(Exception reason, Object propertyId, + Object value) { + /* Return null -> Does not add any filter on failure */ + return null; + } +} @@ -0,0 +1,109 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!--#======================================================================= --> +<!--# Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany). --> +<!--# All rights reserved. This program and the accompanying materials --> +<!--# are made available under the terms of the Eclipse Public License v1.0 --> +<!--# which accompanies this distribution, and is available at --> +<!--# http://www.eclipse.org/legal/epl-v10.html --> +<!--# --> +<!--# Contributors: --> +<!--# Christophe Loetz (Loetz GmbH&Co.KG) - Initial implementation API and implementation --> +<!--#======================================================================= --> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + <modelVersion>4.0.0</modelVersion> + + <parent> + <groupId>org.eclipse.osbp.releng.maven</groupId> + <artifactId>org.eclipse.osbp.releng.maven.parent.tycho</artifactId> + <version>0.9.0-SNAPSHOT</version> + <relativePath/> + </parent> + + <groupId>org.eclipse.osbp.xtext.table.common</groupId> + <artifactId>org.eclipse.osbp.xtext.table.common.aggregator</artifactId> + <version>0.9.0-SNAPSHOT</version> + <packaging>pom</packaging> + + <url>${osbp.site.repository.url}</url> + <scm> + <url>${osbp.scm.url}</url> + <connection>${osbp.scm.connection}</connection> + <developerConnection>${osbp.scm.connection.dev}</developerConnection> + <tag>HEAD</tag> + </scm> + <distributionManagement> + <site> + <id>gh-pages</id> + <name>OSBP GitHub Pages</name> + <url>${distribution.site.url}</url> + </site> + </distributionManagement> + + <properties> + <osbp.gitrepo.name>${project.groupId}</osbp.gitrepo.name> + </properties> + + <modules> + <module>org.eclipse.osbp.xtext.table.common</module> + <module>org.eclipse.osbp.xtext.table.common.feature</module> + <!-- <module>org.eclipse.osbp.xtext.table.common.p2</module> --> + </modules> + + <profiles> + <profile> + <id>build.p2</id> + <activation> + <property> + <name>osbp.build.p2</name> + </property> + </activation> + <modules> + <!-- <module>org.eclipse.osbp.xtext.table.common.p2</module> --> + </modules> + </profile> + </profiles> + <build> + <pluginManagement> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-javadoc-plugin</artifactId> + <configuration> + <skip>true</skip> + </configuration> + </plugin> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <version>${tycho-version}</version> + <configuration> + <resolver>p2</resolver> + <pomDependencies>consider</pomDependencies> + <environments> + <environment> + <os>win32</os> + <ws>win32</ws> + <arch>x86_64</arch> + </environment> + <environment> + <os>linux</os> + <ws>gtk</ws> + <arch>x86</arch> + </environment> + <environment> + <os>linux</os> + <ws>gtk</ws> + <arch>x86_64</arch> + </environment> + <environment> + <os>macosx</os> + <ws>cocoa</ws> + <arch>x86_64</arch> + </environment> + </environments> + </configuration> + </plugin> + </plugins> + </pluginManagement> + </build> +</project> |