// SharedDevicesManager.cs created with MonoDevelop
// User: klose at 16:08 20.12.2010
// CVS release: $Id: SharedDevicesManager.cs,v 1.1 2011-01-06 16:36:28 klose Exp $
//
//    QuickStep: Acquire, view and identify spectra 
//    Copyright (C) 2010  Thomas Klose, Hiperscan GmbH Dresden, Germany
//
//    This program is free software: you can redistribute it and/or modify
//    it under the terms of the GNU General Public License as published by
//    the Free Software Foundation, either version 3 of the License, or
//    (at your option) any later version.
//
//    This program is distributed in the hope that it will be useful,
//    but WITHOUT ANY WARRANTY; without even the implied warranty of
//    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//    GNU General Public License for more details.
//
//    You should have received a copy of the GNU General Public License
//    along with this program.  If not, see <http://www.gnu.org/licenses/>.
//


using System;
using Hiperscan.Unix;

namespace Hiperscan.QuickStep
{
    public enum LicenseTyoe
    {
        GPL3,
        HiperScan,
    }
    public class Licenses
    {
        public static readonly string GPL3 = Catalog.GetString(@"
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see http://www.gnu.org/licenses/ .
");

        public static readonly string HiperScan = Catalog.GetString(@"

QUICKSTEP SOFTWARE LICENSE AGREEMENT

Between the user of the contractually agreed software (hereinafter referred to as “User”) and HiperScan GmbH, Weißeritzstraße 3, 01067 Dresden, Germany (hereinafter referred to as “Licensor”).
PREAMBLE
    1. The licensor distributes analysers and spectrometer-modules, of the company HiperScan GmbH (hereinafter referred to as “Product” or “Products”). The Products serve for near-infrared (NIR) spectroscopy. 
    2. For using the Products, the User requires the software “QuickStep” (hereinafter together referred to as “Contractually Agreed Software”).
    3. The Contractually Agreed Software is intended for being used by business people within the meaning of Section 14 of the German Civil Code. The User shall only be entitled to use of the Contractually Agreed Software in connection with the purchase of a Product from the Licensor.
    4. The following terms and conditions shall govern the type and scope of the permitted use of the Contractually Agreed Software.
    I. SUBJECT MATTER OF THE AGREEMENT
    1. The subject matter of the Agreement shall be the permanent provision of the Contractually Agreed Software (object code) submitted as installer file QuickStep.exe or as Debian package QuickStep.deb, respectively, as well as the provision of the related user documentation and the transfer of the rights of use granted in accordance with item III.
    2. The installation and configuration of the Contractually Agreed Software shall not be a subject matter of the Agreement and shall therefore not be due from the Licensor.
    3. The user documentation shall indicate the nature and functionality of the Contractually Agreed Software.
    II. CONCLUSION OF THE AGREEMENT
If the User agrees to these license terms and conditions within the scope of the installation of the Contractually Agreed Software, a License Agreement with the content of this document shall be concluded.
    III. RIGHTS OF USE
    1. The Licensor shall grant to the User a non-exclusive right to use the Contractually Agreed Software, which is unlimited in terms of time and territory, for the types of use hereinafter described. Rights of use regarding the source code shall not be granted.

    2. The license shall entitle the user to use the Contractually Agreed Software in accordance with this Agreement. This shall include the installation of the Contractually Agreed Software, the upload of the Contractually Agreed Software into the main memory of the device, and running the software for usage. The license shall not cover any other types of use. In particular, the User shall not be entitled to carry out any changes and translations or other reproductions of the Contractually Agreed Software, not even partially or temporarily, irrespective of the type and of the means used for that purpose. Printing the program code shall also be considered as an unauthorised reproduction. It shall be permitted to make changes regarding which the Licensor shall – in accordance with the principles of good faith – not be entitled to withhold their consent (Section 39, subsection 2 of the German Copyright Act).
    3. The User shall not be entitled to reverse engineer, decompile, or disassemble the Contractually Agreed Software or to assist third parties in such activities. In other respects, Sections 69d and 69e of the German Copyright Act shall remain unaffected.
    4. The User shall be entitled to use the provided Contractually Agreed Software exclusively to control Products of the company HiperScan GmbH, to record, save and load spectra from these Products and to display, view and analyse spectra from these Products.
    5. The Licensor or the software developer, respectively, shall remain the owner of all industrial property rights and copyrights in the Contractually Agreed Software as well as the related user documentation. References to copyrights or other industrial property rights on or in the Contractually Agreed Software shall neither be changed or removed nor made unrecognisable in any other way.
    6. The User may provide the Contractually Agreed Software permanently to third parties only together with a Product. Any transfer of the license regarding the Contractually Agreed Software to a third party shall be permitted only after a previous notification of the Licensor and only in the case that the third party agrees in writing to the provisions of this Agreement. In such a case, the user shall completely cease to use the Contractually Agreed Software. The user shall be obliged to delete or render unusable, respectively, all copies of the Contractually Agreed Software. The User shall only be entitled to retain copies of the Contractually Agreed Software (including any previous versions), if the User is required by law to comply with a longer retention period. Furthermore, the User shall not be permitted to rent out the Contractually Agreed Software to third persons or to sublicense it, to reproduce it in public (using a wire or wirelessly), to make it publicly available, or to make it available to third party against a remuneration or free of charge.
    IV. SOFTWARE ENVIRONMENT & PROVISION
    1. In order to be able to use the Contractually Agreed Software, the User shall use one of the following software platforms:
PC with operating system Windows 10 (excluding the starter version), Debian-based Linux, at least a 2 GB main memory, at least 1.6 GHz Pentium, 0.5 GB local storage space.
    2. The Licensor shall not be obliged to examine whether or ensure that the required software environment is available on the User’s computer system. 
    3. The Licensor shall provide the User with the Contractually Agreed Software on a data storage device or via download. The User shall have the user documentation displayed digitally in the Contractually Agreed Software.

    V. WARRANTY
        1. In accordance with the provision of Sections 434 et seqq. of the German Civil Code, the Licensor shall warrant that the Contractually Agreed Software is free of defects of quality and title and complies with the specifications indicated in the user documentation.
        2. In cases in which the defect is attributable to the fact that the User uses the Contractually Agreed Software in a hardware or software environment that does not comply with the requirements indicated in item IV, any warranty shall be excluded. Furthermore, the warranty shall be excluded regarding all changes or modifications that the user makes to the Contractually Agreed Software without being authorised to do so by law, by this Agreement, or on the basis of the Licensor’s previous written consent. 
        3. The Licensor shall correct errors in the Contractually Agreed Software that do not only insubstantially impair its contractually agreed use. At the Licensor’s option, the error shall be corrected by delivering an improved version of the Contractually Agreed Software or by instructions for correcting the error or working around the effects of the error. The User shall be obliged to take over a new version of the Contractually Agreed Software offered to them by the Licensor in the scope of the error correction. In the case of defects of title, the Licensor shall either ensure for the User a lawful way of using the Contractually Agreed Software or change it in a way that does not result in the infringement of third party rights anymore. 
        4. In the case the error correction is not successful, the User shall be entitled to claim a reduction of the licensing fee or to rescind the Agreement. In case of the rescission, the User shall return to the Licensor the respective data storage devices on which the Contractually Agreed Software is stored as well as the related user documentation and shall destroy or delete any possible copies.
        5. The warranty period shall have a duration of 1 year starting at the provision of the Contractually Agreed Software, unless otherwise agreed in a separate agreement.
    VI. LIABILITY
        1. The Licensor shall only be liable for damages the cause of which is based on a grossly negligent or intentional failure to comply with duties or at least on a negligent breach of essential contractual obligations (cardinal obligations). Obligations shall be considered as cardinal obligations if the compliance with them enables the due performance of the Agreement in the first place and the compliance with which the contractual partner therefore does and also may rely on and/or obligations, the infringement of which compromises reaching the purpose of the Agreement. Regarding the cardinal obligations, the liability shall be limited to the amount of the damages that were typically foreseeable. 
        2. The aforementioned limitation of liability shall not be applicable to damages arising from the injury to life, body, or health or as far as the Licensor has granted a guarantee in exceptional cases. In other respects, the liability arising from the imperative statutory product liability provisions applicable in a respective case shall remain unaffected.
        3. The Licensor shall not be liable for any data recovery, unless the Licensor has caused its destruction through gross negligence or intentionally.
        4. The User shall be aware of the fact that within their obligation to minimise any possible damages, they shall be obliged to regularly backup their data and in the case of a suspected damage of the Contractually Agreed Software, they shall take all reasonable additional protective measures.
    VII. FINAL PROVISIONS
        1. Any changes and amendments to or the rescission of this Agreement shall only be valid when made in writing. This shall also apply to the revocation of the aforementioned requirement of the written form. 
        2. Provided that one or several provisions of this License Agreement should be completely or partially invalid or unenforceable, the validity of all other provisions of this License Agreement shall remain unaffected thereby. Any invalid or unenforceable provision shall be deemed to be replaced by a valid and enforceable one that comes closest to the economic purpose of the invalid or unenforceable provision intended by the parties. The same shall apply to any possible gaps in this License Agreement.
        3. This Contract shall be exclusively governed by German law; the United Nations Convention on Contracts for the International Sale of Goods (CISG) shall be excluded.
        4. As far as permitted by law, the place of jurisdiction shall be Dresden.
");
    }
}
