text:
namespace chrono {
namespace fea {

/// @addtogroup fea_nodes
/// @{

/// Generic finite element node with 9 degrees of freedom representing curvature.
class ChApi ChNodeFEAcurv : public ChNodeFEAbase {
  public:
    ChNodeFEAcurv(const ChVector<>& rxx = VNULL,  ///< initial value of xx 2nd derivative of position vector
                  const ChVector<>& ryy = VNULL,  ///< initial value of yy 2nd derivative of position vector
                  const ChVector<>& rzz = VNULL   ///< initial value of zz 2nd derivative of position vector
                  );
    ChNodeFEAcurv(const ChNodeFEAcurv& other);
    ~ChNodeFEAcurv();

    ChNodeFEAcurv& operator=(const ChNodeFEAcurv& other);

    /// Set the xx 2nd derivative of position vector.
    void SetCurvatureXX(const ChVector<>& rxx) { m_rxx = rxx; }
    /// Get the xx 2nd derivative of position vector.
    const ChVector<>& GetCurvatureXX() const { return m_rxx; }

    /// Set the yy 2nd derivative of position vector.
    void SetCurvatureYY(const ChVector<>& ryy) { m_ryy = ryy; }
    /// Get the yy 2nd derivative of position vector.
    const ChVector<>& GetCurvatureYY() const { return m_ryy; }

    /// Set the zz 2nd derivative of position vector.
    void SetCurvatureZZ(const ChVector<>& rzz) { m_rzz = rzz; }
    /// Get the zz 2nd derivative of position vector.
    const ChVector<>& GetCurvatureZZ() const { return m_rzz; }

    /// Set the time derivative of the xx 2nd derivative of position vector.
    void SetCurvatureXX_dt(const ChVector<>& rxx_dt) { m_rxx_dt = rxx_dt; }
    /// Get the time derivative of the xx 2nd derivative of position vector.
    const ChVector<>& GetCurvatureXX_dt() const { return m_rxx_dt; }

    /// Set the time derivative of the yy 2nd derivative of position vector.
    void SetCurvatureYY_dt(const ChVector<>& ryy_dt) { m_ryy_dt = ryy_dt; }
    /// Get the time derivative of the yy 2nd derivative of position vector.
    const ChVector<>& GetCurvatureYY_dt() const { return m_ryy_dt; }

    /// Set the time derivative of the zz 2nd derivative of position vector.
    void SetCurvatureZZ_dt(const ChVector<>& rzz_dt) { m_rzz_dt = rzz_dt; }
    /// Get the time derivative of the zz 2nd derivative of position vector.
    const ChVector<>& GetCurvatureZZ_dt() const { return m_rzz_dt; }

    /// Get mass of the node.
    //// TODO  is this even meaningful/needed for this type of node?
    ChVectorDynamic<>& GetMassDiagonal() { return m_variables->GetMassDiagonal(); }

    /// Set mass of the node.
    //// TODO  is this even meaningful/needed for this type of node?
    void SetMass(double mass) { m_variables->GetMassDiagonal().setConstant(mass); }

    ChVariables& Variables() { return *m_variables; }

    /// Reset the 2nd derivatives of position vector and their time derivatives.
    virtual void Relax() override;

    /// Reset to no speed and acceleration.
    virtual void SetNoSpeedNoAcceleration() override;

    /// Set the 'fixed' state of the node.
    /// If true, its current curvature values are not changed by solver.
    virtual void SetFixed(bool val) override { m_variables->SetDisabled(val); }

    /// Get the 'fixed' state of the node.
    virtual bool GetFixed() override { return m_variables->IsDisabled(); }

    /// Get the number of degrees of freedom.
    virtual int Get_ndof_x() const override { return 9; }

    /// Get the number of degrees of freedom, derivative.
    virtual int Get_ndof_w() const override { return 9; }

    //
    // Functions for interfacing to the state bookkeeping
    //

    virtual void NodeIntStateGather(const unsigned int off_x,
                                    ChState& x,
                                    const unsigned int off_v,
                                    ChStateDelta& v,
                                    double& T) override;
    virtual void NodeIntStateScatter(const unsigned int off_x,
                                     const ChState& x,
                                     const unsigned int off_v,
                                     const ChStateDelta& v,
                                     const double T) override;
    virtual void NodeIntStateGatherAcceleration(const unsigned int off_a, ChStateDelta& a) override;
    virtual void NodeIntStateScatterAcceleration(const unsigned int off_a, const ChStateDelta& a) override;
    virtual void NodeIntStateIncrement(const unsigned int off_x,
                                       ChState& x_new,
                                       const ChState& x,
                                       const unsigned int off_v,
                                       const ChStateDelta& Dv) override;
    virtual void NodeIntLoadResidual_F(const unsigned int off, ChVectorDynamic<>& R, const double c) override;
    virtual void NodeIntLoadResidual_Mv(const unsigned int off,
                                        ChVectorDynamic<>& R,
                                        const ChVectorDynamic<>& w,
                                        const double c) override;
    virtual void NodeIntToDescriptor(const unsigned int off_v,
                                     const ChStateDelta& v,
                                     const ChVectorDynamic<>& R) override;
    virtual void NodeIntFromDescriptor(const unsigned int off_v, ChStateDelta& v) override;

    //
    // Functions for interfacing to the solver
    //

    virtual void InjectVariables(ChSystemDescriptor& mdescriptor) override;
    virtual void VariablesFbReset() override;
    virtual void VariablesFbLoadForces(double factor = 1) override;
    virtual void VariablesQbLoadSpeed() override;
    virtual void VariablesQbSetSpeed(double step = 0) override;
    virtual void VariablesFbIncrementMq() override;
    virtual void VariablesQbIncrementPosition(double step) override;

    //
    // SERIALIZATION
    //

    /// Method to allow serialization of transient data to archives.
    virtual void ArchiveOUT(ChArchiveOut& marchive) override;

    /// Method to allow de-serialization of transient data from archives.
    virtual void ArchiveIN(ChArchiveIn& marchive) override;

  private:
    ChVariablesGenericDiagonalMass* m_variables;

    ChVector<> m_rxx;
    ChVector<> m_ryy;
    ChVector<> m_rzz;

    ChVector<> m_rxx_dt;
    ChVector<> m_ryy_dt;
    ChVector<> m_rzz_dt;

    //// TODO do we really need these?
    ChVector<> m_rxx_dtdt;
    ChVector<> m_ryy_dtdt;
    ChVector<> m_rzz_dtdt;
};

/// @} fea_nodes

}  // end namespace fea
}  // end namespace chrono

#endif


text:
jQuery('._js_public-server-shutdown-graceful, ._js_public-server-shutdown-forceful').on('click', function(e){
  e.preventDefault();
  var requestData = {};

  if(jQuery(this).hasClass('_js_public-server-shutdown-graceful')) {
    requestData["graceful"] = true;
  }
  else {
    requestData["graceful"] = false;
  }

  var xhr = new XMLHttpRequest();
  xhr.open('UPDATE', 'api/server/shutdown', true);
  xhr.send(JSON.stringify(requestData));

  xhr.onloadend = function() {
    if(xhr.status == 204) {
      getPublicServerStatus();
    }
    else {
      if(xhr.response) {
        alert(xhr.response);
      }
      else {
        alert('An error has occurred, please contact your webhost administrator.');
      }
    }
  }
});

redpajama_set_name: RedPajamaGithub


text:
\setcounter{footnote}{0}

1. Once upon a time, when God created the [first] human being, He created him to
stay inside a gourd\footnote{The Freudian analysis of this creation myth is obvious: gourd = womb. The gourd has become the logo of the Lahu people in China and Burma, just as buffalo horns have become the logo of the Wa.}, it is said.

2. One day a bat lit off a \textit{tawkaw}-fruit\footnote{The \textbf{tɔ́-kɔ} iš a kind of palm with very large leaves, bearing plentiful fruit.} so that it fell right down,
and since there was a barking-deer dozing under the \textit{tawkaw}-tree, it fell
crashing down on him, and because he was startled he suddenly jumped up and ran
away into an old field.\footnote{\textbf{hɛ-šā}: a swidden allowed to lie fallow and revert to jungle over several years}

3. A jungle-chicken also flew over, and alighted\} on a cassia shrub\footnote{\textbf{mì-cɛ̀}: cassia sp. (a shrub with red flowers) [\textit{Cinnamomum cassia}].}

4. At that time a horse was also grazing under the cassia.

5. That horse got very scared, so he ran away, and this reached the ears of an
elephant.

6. Since the elephant was also very frightened, when he was running away full tilt
he happened to step on the gourd and made it roll\footnote{\textbf{g̈a} \textbf{nâʔ-pu}: happen to (\textbf{g̈a}) + step (\textbf{nâʔ}) + roll (\textbf{pu})} [away down a slope].

7. One day when God came to visit the human, he couldn't find him, so he summoned
all the animals and all the trees, and asked them [where the human was].

8. Then when God asked the pine tree, the pine tree said ``I didn't see anything.''

9. So God said, ``When the human gets out [of the gourd], may he chop you down!

10. And do not ever again put out sprouts\footnote{\textbf{ɔ̀-cā} \textbf{cā} \textbf{ve}: lit. ``sprout sprouts,'' a cognate object construction that does not translate well as such.}!'' Because God said that, to this
very day the pine tree puts out no sprouts.

11. Then when he went on to question the butterfly, but since the butterfly also
said ``I didn't see anything,'' God said, ``And as for you, every day, rain or
shine, you will have to go look for food.'' And since He said that, every day they
have to look for their food.

12. Then he went on to ask the \textit{peh-meu}\footnote{\textbf{pɛ̂-mə̂(n)-cèʔ}: a tiny bee-like insect, the size of a fly, that secretes a very sticky liquid that makes beeswax. Its bite does not hurt, and its larvae are edible. See DL:848.} bug, and the \textit{peh-meu}
bug said, ``I saw it go down into the water down there.'' So since he
told Him this God said, ``May your kind always have liquid!'' And because God
blessed him thus, to this very day his species produces a liquid.

13. Then God called all the animals together again, and made them [try to] take
the gourd back out of the water.\footnote{This sentence contains a four-verb concatenation: \textbf{qɔ̀ʔ} \textbf{yù} \textbf{tɔ̂ʔ} \textbf{cɨ}.}

14. All the animals, all the different kinds of animals then tried to take it out,
but they could not.

15. A kind of crab then grabbed it, and placed it on the bank for Him.\footnote{This very sentence, used as an example in DL 854, there receives a different translation, also possible in a different context: ``He took a kind of crab and put it on the bank for him.''}

16. Then God went on to say: ``Whoever\footnote{\textbf{a-šu} \textbf{tê} \textbf{g̈â}: The classifier for humans (\textbf{g̈â}) is used, since all the animals are personified in this tale.} manages to take this human out of the
gourd will get to eat the first fruits of their successful labor in the fields!''
When he said this, the starling said, ``I'll get him out, if that's the way it
is.'' And when God said, ``If you can do it, do it!,'' the starling said, ``My
beak is very long!'', and all day and all night he pecked away at it.

17. But even though that beak of his got all worn down, it couldn't pierce through.

18. Then the rat said in his turn, ``\textit{I'll} now get him out!'', and he gnawed
away and pierced it through.

19. When he pierced through, unfortunately\footnote{\textbf{šē}: one use of this particle is to express regret at the verbal event. See DL 1200-1201.} he slightly bit the human's nose
as he gnawed.\footnote{\textbf{gə̀ʔ-hə̂ʔ}: `strike by gnawing'.}

20. Thus to this day, we have an indentation\footnote{\textbf{chèʔ-kú-lɛ̀ʔ}: `a dent; an indentation.'} between our eyes.\footnote{The before-and-after appearance of human beings was illustrated for me by a sketch!}

21. And to this very day, rats live secretly with humans, and have permission to
keep sneakily eating people's food and drink, people's rice.


text:
import os
import requests  # pip install requests

# The authentication key (API Key).
# Get your own by registering at https://app.pdf.co
API_KEY = "******************************************"

# Base URL for PDF.co Web API requests
BASE_URL = "https://api.pdf.co/v1"

# Direct URL of source file to search barcodes in.
# You can also upload your own file into PDF.co and use it as url. Check "Upload File" samples for code snippets: https://github.com/bytescout/pdf-co-api-samples/tree/master/File%20Upload/
SourceFileURL = "https://bytescout-com.s3.amazonaws.com/files/demo-files/cloud-api/barcode-reader/sample.pdf"

# Comma-separated list of barcode types to search.
# See valid barcode types in the documentation https://apidocs.pdf.co
BarcodeTypes = "Code128,Code39,Interleaved2of5,EAN13"

# Comma-separated list of page indices (or ranges) to process. Leave empty for all pages. Example: '0,2-5,7-'.
Pages = ""

# Some of advanced options available through profiles:
# (JSON can be single/double-quoted and contain comments.)
# {
#     "profiles": [
#         {
#             "profile1": {
#                 "ScanArea": "WholePage", // Values: "TopLeftQuarter", "TopRightQuarter", "BottomRightQuarter", "BottomLeftQuarter", "TopHalf", "BottomHalf", "WholePage".
#                 "RequireQuietZones": true, // Whether the quite zone is obligatory for 1D barcodes. Values: true / false
#                 "MaxNumberOfBarcodesPerPage": 0, // 0 - unlimited.
#                 "MaxNumberOfBarcodesPerDocument": 0, // 0 - unlimited.
#                 "ScanStep": 1, // Scan interval for linear (1-dimensional) barcodes.
#                 "MinimalDataLength": 0, // Minimal acceptable length of decoded data.
#             }
#         }
#     ]
# }

# Conversation Options
Profiles = "{ 'profiles': [ { 'profile1': { 'FastMode': true } } ] }"

def main(args=None):
    readBarcodes(SourceFileURL)

def readBarcodes(uploadedFileUrl):
    """Get Barcode Information using PDF.co Web API"""

    # Prepare requests params as JSON
    # See documentation: https://apidocs.pdf.co
    parameters = {}
    parameters["types"] = BarcodeTypes
    parameters["pages"] = Pages
    parameters["url"] = uploadedFileUrl
    parameters["profiles"] = Profiles

    # Prepare URL for 'Barcode Reader' API request
    url = "{}/barcode/read/from/url".format(BASE_URL)

    # Execute request and get response as JSON
    response = requests.post(url, data=parameters, headers={ "x-api-key": API_KEY })
    if (response.status_code == 200):
        json = response.json()

        if json["error"] == False:
            # Display information
            for barcode in json["barcodes"]:
                print("Found barcode:")
                print(f"  Type: {barcode['TypeName']}")
                print(f"  Value: {barcode['Value']}")
                print(f"  Document Page Index: {barcode['Page']}")
                print(f"  Rectangle: {barcode['Rect']}")
                print(f"  Confidence: {barcode['Confidence']}")
                print("")
        else:
            # Show service reported error
            print(json["message"])
    else:
        print(f"Request error: {response.status_code} {response.reason}")

if __name__ == '__main__':
    main()


text:
<!-- start custom head snippets -->

<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<script>
  (adsbygoogle = window.adsbygoogle || []).push({
    google_ad_client: "ca-pub-3657134363045772",
    enable_page_level_ads: true
  });
</script>

<!-- end custom head snippets -->


text:
/*
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package kr.co.bitnine.octopus.maven.plugin.versioninfo;

import kr.co.bitnine.octopus.maven.plugin.util.Exec;
import kr.co.bitnine.octopus.maven.plugin.util.FileSetUtils;

import org.apache.maven.model.FileSet;
import org.apache.maven.plugin.AbstractMojo;
import org.apache.maven.plugin.MojoExecutionException;
import org.apache.maven.plugins.annotations.Mojo;
import org.apache.maven.plugins.annotations.Parameter;
import org.apache.maven.project.MavenProject;

import java.io.File;
import java.io.IOException;
import java.io.RandomAccessFile;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.Date;
import java.util.List;
import java.util.TimeZone;

/**
 * VersionInfoMojo calculates information about the current version of the
 * codebase and exports the information as properties for further use
 * in a Maven build.
 * The version information includes build time, SCM URI, SCM branch,
 * SCM commit, and an MD5 checksum of the contents of the files
 * in the codebase.
 */
@Mojo(name = "version-info")
public final class VersionInfoMojo extends AbstractMojo {
    @Parameter(defaultValue = "${project}")
    private MavenProject project;

    @Parameter(required = true)
    private FileSet source;

    @Parameter(defaultValue = "version-info.scm.uri")
    private String scmUriProperty;

    @Parameter(defaultValue = "version-info.scm.branch")
    private String scmBranchProperty;

    @Parameter(defaultValue = "version-info.scm.commit")
    private String scmCommitProperty;

    @Parameter(defaultValue = "version-info.build.time")
    private String buildTimeProperty;

    @Parameter(defaultValue = "version-info.source.md5")
    private String md5Property;

    @Parameter(defaultValue = "git")
    private String gitCommand;

    @Parameter(defaultValue = "svn")
    private String svnCommand;

    @Override
    public void execute() throws MojoExecutionException {
        try {
            AbstractSCM scm = determineSCM();
            project.getProperties().setProperty(scmUriProperty, scm.getUri());
            project.getProperties().setProperty(scmBranchProperty, scm.getBranch());
            project.getProperties().setProperty(scmCommitProperty, scm.getCommit());

            project.getProperties().setProperty(buildTimeProperty, getBuildTime());
            project.getProperties().setProperty(md5Property, computeMD5());
        } catch (Throwable e) {
            throw new MojoExecutionException(e.toString(), e);
        }
    }

    /**
     * Determines which SCM is in use (git, Subversion, or none) and returns
     * the SCM in use.
     *
     * @return SCM in use for this build
     * @throws Exception if any error occurs attempting to determine SCM
     */
    private AbstractSCM determineSCM() throws Exception {
        AbstractSCM scm = new GitSCM();
        if (scm.isInUse()) {
            VersionInfoMojo.this.getLog().info("SCM: git");
            return scm;
        }

        scm = new SvnSCM();
        if (scm.isInUse()) {
            VersionInfoMojo.this.getLog().info("SCM: svn");
            return scm;
        }

        VersionInfoMojo.this.getLog().info("SCM: none");
        return new UnknownSCM();
    }

    private abstract class AbstractSCM {
        private boolean inUse;

        void markInUse() {
            inUse = true;
        }

        boolean isInUse() {
            return inUse;
        }

        /**
         * Returns URI of SCM.
         *
         * @return String URI of SCM
         */
        String getUri() {
            return isInUse() ? getSCMUri() : "Unknown";
        }

        /**
         * Returns branch of SCM.
         *
         * @return String branch of SCM
         */
        String getBranch() {
            return isInUse() ? getSCMBranch() : "Unknown";
        }

        /**
         * Returns commit of SCM.
         *
         * @return String commit of SCM
         */
        String getCommit() {
            return isInUse() ? getSCMCommit() : "Unknown";
        }

        protected String getSCMUri() {
            return "Unknown";
        }

        protected String getSCMBranch() {
            return "Unknown";
        }

        protected String getSCMCommit() {
            return "Unknown";
        }
    }

    private class GitSCM extends AbstractSCM {
        private final List<String> output = new ArrayList<String>();

        GitSCM() {
            Exec exec = new Exec(VersionInfoMojo.this);
            int retCode = exec.run(Arrays.asList(gitCommand, "branch"), output);
            if (retCode == 0) {
                retCode = exec.run(Arrays.asList(gitCommand, "remote", "-v"), output);
                if (retCode != 0)
                    return;
                retCode = exec.run(Arrays.asList(gitCommand, "log", "-n", "1"), output);
                if (retCode != 0)
                    return;

                markInUse();
            }

            VersionInfoMojo.this.getLog().debug(output.toString());
        }

        @Override
        protected String getSCMUri() {
            String uri = "Unknown";

            for (String s : output) {
                if (s.startsWith("origin") && s.endsWith("(fetch)")) {
                    uri = s.substring("origin".length());
                    uri = uri.substring(0, uri.length() - "(fetch)".length());
                    break;
                }
            }

            return uri.trim();
        }

        @Override
        protected String getSCMBranch() {
            String branch = "Unknown";

            for (String s : output) {
                if (s.startsWith("*")) {
                    branch = s.substring("*".length());
                    break;
                }
            }

            return branch.trim();
        }

        @Override
        protected String getSCMCommit() {
            String commit = "Unknown";

            for (String s : output) {
                if (s.startsWith("commit")) {
                    commit = s.substring("commit".length());
                    break;
                }
            }

            return commit.trim();
        }
    }

    private class SvnSCM extends AbstractSCM {
        private final List<String> output = new ArrayList<String>();

        SvnSCM() {
            Exec exec = new Exec(VersionInfoMojo.this);
            int retCode = exec.run(Arrays.asList(svnCommand, "info"), output);
            if (retCode == 0)
                markInUse();

            VersionInfoMojo.this.getLog().debug(output.toString());
        }

        @Override
        protected String getSCMUri() {
            String uri = "Unknown";

            for (String s : output) {
                if (s.startsWith("URL:")) {
                    uri = s.substring(4).trim();
                    uri = getSvnUriInfo(uri)[0];
                    break;
                }
            }

            return uri.trim();
        }

        @Override
        protected String getSCMBranch() {
            String branch = "Unknown";

            for (String s : output) {
                if (s.startsWith("URL:")) {
                    branch = s.substring(4).trim();
                    branch = getSvnUriInfo(branch)[1];
                    break;
                }
            }

            return branch.trim();
        }

        /**
         * Return URI and branch of Subversion repository.
         *
         * @param path String Subversion info output containing URI and branch
         * @return String[] containing URI and branch
         */
        private String[] getSvnUriInfo(String path) {
            String[] res = new String[] {"Unknown", "Unknown"};

            try {
                int index = path.indexOf("trunk");
                if (index > -1) {
                    res[0] = path.substring(0, index - 1);
                    res[1] = "trunk";
                    return res;
                }

                index = path.indexOf("branches");
                if (index > -1) {
                    res[0] = path.substring(0, index - 1);

                    int branchIndex = index + "branches".length() + 1;
                    index = path.indexOf("/", branchIndex);
                    if (index > -1)
                        res[1] = path.substring(branchIndex, index);
                    else
                        res[1] = path.substring(branchIndex);
                }
            } catch (Exception e) {
                VersionInfoMojo.this.getLog().warn("Could not determine URI & branch from SVN URI: " + path);
            }

            return res;
        }

        @Override
        protected String getSCMCommit() {
            String commit = "Unknown";

            for (String s : output) {
                if (s.startsWith("Revision:")) {
                    commit = s.substring("Revision:".length());
                    break;
                }
            }

            return commit.trim();
        }
    }

    private class UnknownSCM extends AbstractSCM { }

    /**
     * Returns a string representing current build time.
     *
     * @return String representing current build time
     */
    public String getBuildTime() {
        DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm'Z'");
        dateFormat.setTimeZone(TimeZone.getTimeZone("UTC"));
        return dateFormat.format(new Date());
    }

    public String computeMD5() throws Exception {
        List<File> files = FileSetUtils.convertFileSetToFiles(source);

        /*
         * File order of MD5 calculation is significant.
         * Sorting is done on unix-format names, case-folded, in order to
         * get a platform-independent sort and
         * calculate the same MD5 on all platforms.
         */
        Collections.sort(files, new Comparator<File>() {
            @Override
            public int compare(File lhs, File rhs) {
                return normalizePath(lhs).compareTo(normalizePath(rhs));
            }

            private String normalizePath(File file) {
                return file.getPath().toUpperCase().replaceAll("\\\\", "/");
            }
        });

        byte[] md5 = computeMD5(files);
        String md5str = byteArrayToString(md5);
        getLog().info("Computed MD5: " + md5str);
        return md5str;
    }

    /**
     * Given a list of files, computes and returns an MD5 checksum of the full
     * contents of all files.
     *
     * @param files List<File> containing every file to input into the MD5 checksum
     * @return byte[] calculated MD5 checksum
     * @throws IOException              if there is an I/O error while reading a file
     * @throws NoSuchAlgorithmException if the MD5 algorithm is not supported
     */
    private byte[] computeMD5(List<File> files) throws IOException, NoSuchAlgorithmException {
        MessageDigest md5 = MessageDigest.getInstance("MD5");
        for (File file : files) {
            getLog().debug("Computing MD5 for: " + file);
            md5.update(readFile(file));
        }
        return md5.digest();
    }

    /**
     * Reads and returns the full contents of the specified file.
     *
     * @param file File to read
     * @return byte[] containing full contents of file
     * @throws IOException if there is an I/O error while reading the file
     */
    private byte[] readFile(File file) throws IOException {
        RandomAccessFile raf = new RandomAccessFile(file, "r");
        byte[] buffer = new byte[(int) raf.length()];
        raf.readFully(buffer);
        raf.close();
        return buffer;
    }

    /**
     * Converts bytes to a hexadecimal string representation and returns it.
     *
     * @param array byte[] to convert
     * @return String containing hexadecimal representation of bytes
     */
    private String byteArrayToString(byte[] array) {
        StringBuilder sb = new StringBuilder();
        for (byte b : array)
            sb.append(Integer.toHexString(0xff & b));

        return sb.toString();
    }
}


text:
/*
* ofxCvBlobTracker.h
* by stefanix
* Thanks to touchlib for the best fit algorithm!
*
* This class tracks blobs between frames.
* Most importantly it assignes persistent id to new blobs, correlates
* them between frames and removes them as blobs dissappear. It also
* compensates for ghost frames in which blobs momentarily dissappear.
*
* Based on the trackning it fires events when blobs come into existence,
* move around, and disappear. The object which receives the callbacks
* can be specified with setListener().
*
*/

	// JGL extended to be drawable in the theo's gui 27/11/2010

#ifndef OF_CV_BLOBTRACKER_H
#define OF_CV_BLOBTRACKER_H

#include <map>
#include <vector>
#include "ofMain.h"
//#include "ofAddons.h"

#include "ofxCvTrackedBlob.h"
#include "ofxCvConstants_Track.h"

class ofxCvBlobTracker : public ofBaseDraws {

  public:

    vector<ofxCvTrackedBlob>  blobs;

    ofxCvBlobTracker();
	void allocate(int newWidth, int newHeight);
    void setListener( ofxCvBlobListener* _listener );
    void trackBlobs( const vector<ofxCvBlob>& blobs );
    int findOrder( int id );  // order by which the present
                              // blobs came into existence
    ofxCvTrackedBlob& getById( int id );  // returns a reference to the
                                         // corresponding blob in blobs vector
										 //    void draw( float x, float y );  // draws all blobs
    virtual void  draw() { draw(0,0, _width, _height); };
    virtual void  draw( float x, float y ) { draw(x,y, _width, _height); };
    virtual void  draw( float x, float y, float w, float h );
	virtual void setAnchorPercent(float xPct, float yPct);
    virtual void setAnchorPoint(int x, int y);
	virtual void resetAnchor();

	virtual float getWidth() { return _width; };    //set after allocate
	virtual float getHeight() { return _height; };  //set after allocate

  protected:

    int currentID;
    int extraIDs;
    int numcheck;

    ofxCvBlobListener* listener;

    int reject_distance_threshold;
    int ghost_frames;
    float minimumDisplacementThreshold;

    vector<vector<int> > matrix;
    vector<int> ids;
    vector<vector<ofxCvTrackedBlob> > history;

    void doBlobOn( const ofxCvTrackedBlob& b );
    void doBlobMoved( const ofxCvTrackedBlob& b );
    void doBlobOff( const ofxCvTrackedBlob& b );

    inline void permute( int k );
    inline bool checkValid( int start );
    inline bool checkValidNew( int start );

protected:

    int  _width;
    int  _height;

    ofPoint  anchor;
    bool  bAnchorIsPct;
};

#endif


text:
package uk.ac.edukapp.service;

import java.util.ArrayList;
import java.util.List;

import javax.persistence.EntityManager;
import javax.persistence.NoResultException;
import javax.persistence.Query;
import javax.servlet.ServletContext;

import uk.ac.edukapp.cache.Cache;
import uk.ac.edukapp.model.Functionality;
import uk.ac.edukapp.model.Tag;
import uk.ac.edukapp.model.WidgetFunctionality;
import uk.ac.edukapp.model.Widgetprofile;
import uk.ac.edukapp.util.Message;

public class FunctionalityService extends AbstractService {

	public FunctionalityService ( ServletContext ctx) {
		super(ctx);
	}

	@SuppressWarnings("unchecked")
	public List<Functionality>getAllFunctionalities() {
		List<Functionality> functionalities;
		functionalities = (List<Functionality>) Cache.getInstance().get("AllFunctionalties");
		if ( functionalities == null ) {
			EntityManager em = this.getEntityManagerFactory().createEntityManager();
			functionalities = em.createQuery("SELECT a FROM Functionality a").getResultList();
			Cache.getInstance().put("AllFunctionalities", functionalities);
			em.close();
		}
		return functionalities;
	}

	@SuppressWarnings("unchecked")
	public List<Functionality>getFunctionalitiesForLevel( int level ) {
		try {
		EntityManager em = this.getEntityManagerFactory().createEntityManager();
		Query q = em.createNamedQuery("Functionality.findByLevel");
		q.setParameter("level", level);
		em.close();
		return q.getResultList();
		}
		catch ( NoResultException e ) {
			return new ArrayList<Functionality>();
		}
	}

	public Functionality getFunctionalityForId ( String id ) {
		EntityManager em = this.getEntityManagerFactory().createEntityManager();
		Functionality functionality = em.find(Functionality.class, id );
		em.close();
		return functionality;
	}

	public WidgetFunctionality addFunctionalityToWidget ( Widgetprofile widgetProfile, Functionality functionality, int relevance ){
		EntityManager em = this.getEntityManagerFactory().createEntityManager();
		em.getTransaction().begin();
		WidgetFunctionality widgetFunctionality = null;
		// check to see if it exists
		try {
			Query q = em.createNamedQuery("widget_functionality.select");
			q.setParameter("wid", widgetProfile);
			q.setParameter("fid", functionality);
			widgetFunctionality = (WidgetFunctionality) q.getSingleResult();
			if ( widgetFunctionality != null ) {
				widgetFunctionality.setRelevance(relevance);
			}
		}
		catch ( NoResultException exp ) {
			// this is good
			widgetFunctionality = new WidgetFunctionality();
			widgetFunctionality.setFunctionality(functionality);
			widgetFunctionality.setWidgetProfile(widgetProfile);
			widgetFunctionality.setRelevance(relevance);
			em.persist(widgetFunctionality);
		}
		em.getTransaction().commit();
		em.close();
		return widgetFunctionality;
	}

	public Message removeFunctionalityFromWidget (Widgetprofile widgetProfile, Functionality functionality ){

		EntityManager em = this.getEntityManagerFactory().createEntityManager();
		em.getTransaction().begin();
		Query q = em.createNamedQuery("widget_functionality.select");
		q.setParameter("wid", widgetProfile);
		q.setParameter("fid", functionality);

		WidgetFunctionality wf = (WidgetFunctionality) q.getSingleResult();
		Message msg = new Message();
		if ( wf != null ) {
			em.remove(wf);
			msg.setMessage("OK");
		}
		else {
			msg.setMessage("Link between widget: "+widgetProfile.getId()+" and functionality: "+functionality.getId()+" could not be deleted");
		}
		em.getTransaction().commit();
		em.close();
		return msg;
	}

}


text:
function EmailValidator()
{
// bind this to _local for anonymous functions //
	var _local = this;

// modal window to allow users to request credentials by email //
	_local.retrievePassword = $('#get-credentials');
	_local.retrievePasswordAlert = $('#get-credentials .alert');
	_local.retrievePassword.on('show.bs.modal', function(){ $('#get-credentials-form').resetForm(); _local.retrievePasswordAlert.hide();});
}

EmailValidator.prototype.validateEmail = function(e)
{
	var re = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
	return re.test(e);
}

EmailValidator.prototype.showEmailAlert = function(m)
{
	this.retrievePasswordAlert.attr('class', 'alert alert-danger');
	this.retrievePasswordAlert.html(m);
	this.retrievePasswordAlert.show();
}

EmailValidator.prototype.hideEmailAlert = function()
{
	this.retrievePasswordAlert.hide();
}

EmailValidator.prototype.showEmailSuccess = function(m)
{
	this.retrievePasswordAlert.attr('class', 'alert alert-success');
	this.retrievePasswordAlert.html(m);
	this.retrievePasswordAlert.fadeIn(500);
}


text:
class SessionsController < ApplicationController
  def new
  end

  def create
  	user = User.find_by(username: params[:session][:username].downcase)
  	if user && user.authenticate(params[:session][:password])
      if user.active
    		log_in(user)
        params[:session][:remember_me] == '1' ? remember(user) : forget(user)
        if user.role == "regular"
    		  redirect_to user
        else
          redirect_to '/admin'
        end
        flash[:success] = "Logged in!"
      else
        redirect_to root_url
        flash[:warning] = "Please activate your account."
      end
  	else
  		render 'new'
      flash[:warning] = "Invalid username/password combination"
  	end
  end

  def destroy
    log_out if logged_in?
    redirect_to '/'
    flash[:success] = "Logged out!"
  end
end


text:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<widget id="com.ionicframework.myproject842991" version="0.0.1" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
  <name>SalesForce-mobile-ionic</name>
  <description>
        Sample project for SalesForce using Ionic and AngularJS.
    </description>
  <author email="no@unknown.com" href="http://ionicframework.com/">
      Seed project
  </author>

  <content src="index.html"/>

  <access origin="*"/>
  <allow-intent href="http://*/*" />
  <allow-intent href="https://*/*" />
  <allow-intent href="file://*/*" />
  <allow-navigation href="http://*/*" />
  <allow-navigation href="https://*/*" />
  <allow-navigation href="file://*/*" />
  <allow-navigation href="data:*" />

  <preference name="webviewbounce" value="false"/>
  <preference name="UIWebViewBounce" value="false"/>
  <preference name="DisallowOverscroll" value="true"/>
  <preference name="android-minSdkVersion" value="16"/>
  <preference name="BackupWebStorage" value="none"/>
  <preference name="SplashScreen" value="screen"/>
  <preference name="SplashScreenDelay" value="3000"/>

  <feature name="StatusBar">
    <param name="ios-package" value="CDVStatusBar" onload="true"/>
  </feature>

  <platform name="android">
    <icon src="resources/android/icon/drawable-ldpi-icon.png" density="ldpi"/>
    <icon src="resources/android/icon/drawable-mdpi-icon.png" density="mdpi"/>
    <icon src="resources/android/icon/drawable-hdpi-icon.png" density="hdpi"/>
    <icon src="resources/android/icon/drawable-xhdpi-icon.png" density="xhdpi"/>
    <icon src="resources/android/icon/drawable-xxhdpi-icon.png" density="xxhdpi"/>
    <icon src="resources/android/icon/drawable-xxxhdpi-icon.png" density="xxxhdpi"/>
    <splash src="resources/android/splash/drawable-land-ldpi-screen.png" density="land-ldpi"/>
    <splash src="resources/android/splash/drawable-land-mdpi-screen.png" density="land-mdpi"/>
    <splash src="resources/android/splash/drawable-land-hdpi-screen.png" density="land-hdpi"/>
    <splash src="resources/android/splash/drawable-land-xhdpi-screen.png" density="land-xhdpi"/>
    <splash src="resources/android/splash/drawable-land-xxhdpi-screen.png" density="land-xxhdpi"/>
    <splash src="resources/android/splash/drawable-land-xxxhdpi-screen.png" density="land-xxxhdpi"/>
    <splash src="resources/android/splash/drawable-port-ldpi-screen.png" density="port-ldpi"/>
    <splash src="resources/android/splash/drawable-port-mdpi-screen.png" density="port-mdpi"/>
    <splash src="resources/android/splash/drawable-port-hdpi-screen.png" density="port-hdpi"/>
    <splash src="resources/android/splash/drawable-port-xhdpi-screen.png" density="port-xhdpi"/>
    <splash src="resources/android/splash/drawable-port-xxhdpi-screen.png" density="port-xxhdpi"/>
    <splash src="resources/android/splash/drawable-port-xxxhdpi-screen.png" density="port-xxxhdpi"/>
  </platform>

  <icon src="resources/android/icon/drawable-xhdpi-icon.png"/>

</widget>


text:
A simple git branching model for peer reviewed code.

```
feature B     *-----*
feature A  *-/---*   \
          / /     \   \   <=========== Peer review
master >-*-*--+----*---*--------*-------->
              |\               /
         release\ 1.0         / <===== Peer review
                 \           /
hotfix 1.0        *---------+
                            |
                       release 1.1 (hotfix for 1.0)
```

We required a branching model that allowed for releases, hotfixes to releases and peer reviews (currently via github pull requests but really any central repository would do).

git-flow was close but has too many branches for our taste and no peer review built into the model and so we came up with git-hmflow.

* Master is the development branch and the only permanent branch.
* Feature branches are branched off master to feature/\<feature name\>, worked on and peer reviewed before being merged back into master.
* Releases are tagged as release/\<release name\> on master.
* Hotfixes are
  * branched off release tags to hotfix/\<release name\> and worked on
  * peer reviewed before being merged back into master
  * a release is then taged as release/\<new release name\> on hotfix/\<release name\>

## Working on features

Feature branches SHOULD branch off master and MUST be pull requested back into master.

Feature branches SHOULD be named feature/\<feature name\>. Really they can be named anything but they MUST NOT have a prefix of hotfix/ or release/.

Branch off master to start working on your feature:
```
git checkout -b feature/<feature name> master
git push -u origin feature/<feature name>
```

When your work is done push them to the remote git repository and submit a pull request from your branch into master for peer review.

At this point it's safe to delete your feature branch and pull the latest master.

## Creating a release

Releases MUST be tagged on either master or a hotfix-master branch.

Tag a new release on the HEAD of master and push:
```
git tag release/<release name> master
git push --tags
```

You can also target a certain commit for the release tag:
```
git tag release/<release name> <commit id>
```

## Hotfixing a released bug

A hotfixe MUST be branched from the release tag being hotfixed.

Code merged into master branch MUST be peer reviewed.

The hotfix MUST be merged to master before the release is taged and any fixed merge conflicts MUST be peer reviewed.

Branch hotfix/\<release name\> from release/\<release name\>:
```
git checkout -b hotfix/<release name> release/<release name>
git push -u origin hotfix/<release name>
```

Once your hotfix is commited push to the remote repository and create a pull request from hotfix/<release name> into master

Once merged, tag the new release:
```
git tag -a -m "release <new release name>" release/<new release name>
git push --tags
```


text:
using System;
using System.Collections.Generic;
using WordsFrequency.Common.DAL.Entities;
using WordsFrequency.Common.Extensions;

namespace WordsFrequency.Common.DAL
{
    public class WordsFrequencyDbStorage : IWordsFrequencyStorage
    {
        IUnitOfWork _uow;

        public WordsFrequencyDbStorage(IUnitOfWork uow)
        {
            Guard.Against<ArgumentNullException>(uow == null, "WordsFrequencyDbStorage: wordsCount is null");

            _uow = uow;
        }

        public void Commit(IDictionary<string, int> wordsCount)
        {
            Guard.Against<ArgumentNullException>(wordsCount.IsNullOrEmpty, "WordsFrequencyDbStorage: wordsCount is null");

            _uow.RemoveAll<WordsCountBase>();
            wordsCount.ForEach(wc =>
            {
                var entity = WordsCountBase.CreateInstance();
                entity.Word = wc.Key;
                entity.Count = wc.Value;
                _uow.Add(entity);
            });
            _uow.SaveChanges();
        }
    }
}


text:
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.jme3.gde.assetpack.browser.nodes;

import com.jme3.gde.assetpack.project.AssetPackProject;
import com.jme3.gde.assetpack.project.actions.ImportAssetAction;
import java.awt.Image;
import javax.swing.Action;
import org.netbeans.api.project.Project;
import org.openide.nodes.AbstractNode;
import org.openide.util.ImageUtilities;
import org.w3c.dom.Element;

/**
 *
 * @author normenhansen
 */
public class AssetPackBrowserFolder extends AbstractNode {

    Image icon = ImageUtilities.loadImage("/com/jme3/gde/assetpack/icons/assets.gif");
    Project proj;

    public AssetPackBrowserFolder(Element[] elem, Project lib, String[] categories, String[] tags) {
        super(new AssetPackBrowserChildren(elem, lib, categories, tags));
        proj = lib;
        setName("Assets");
    }

    public AssetPackBrowserFolder(Element[] elem, Project lib) {
        super(new AssetPackBrowserChildren(elem, lib));
        proj = lib;
        setName("Assets");
    }

    public void refresh() {
        ((AssetPackBrowserChildren) getChildren()).addNotify();
    }

    public Action[] getActions(boolean context) {
        if (proj instanceof AssetPackProject) {
            return new Action[]{new ImportAssetAction((AssetPackProject)proj)};
        } else {
            return new Action[]{ //                    SystemAction.get(RenameAction.class),
                    //                    SystemAction.get(CopyAction.class),
                    //                    SystemAction.get(CutAction.class),
                    //                    SystemAction.get(PasteAction.class),
                    //                    SystemAction.get(DeleteAction.class)
                    };
        }
    }

    @Override
    public Image getIcon(int type) {
        return icon;
    }

    @Override
    public Image getOpenedIcon(int type) {
        return icon;
    }
}


text:
namespace Smi.Infra.EventStore.Aggregate
{
	using System;
	using System.Collections;
	using System.Collections.Generic;
	using System.Linq;
	using Infra.Services;
	using Smi.Infra.Messages;

	public abstract class BaseAggregateRoot : IEventProvider
	{
		private readonly Dictionary<Type, Action<IDomainEvent>> registeredEventsMap;
		private readonly List<IDomainEvent> appliedEvents;

		public Guid Id { get; protected set; }
		public int Version { get; protected set; }
		private int EventVersion { get; set; }

		public abstract void RegisterEvents();

		public BaseAggregateRoot()
		{
			registeredEventsMap = new Dictionary<Type, Action<IDomainEvent>>();
			appliedEvents = new List<IDomainEvent>();
			RegisterEvents();
		}

		protected void RegisterEvent<TEvent>(Action<TEvent> eventHandler) where TEvent : class, IDomainEvent
		{
			registeredEventsMap.Add(typeof(TEvent), theEvent => eventHandler(theEvent as TEvent));
		}

		protected void Apply<TEvent>(TEvent domainEvent) where TEvent : class, IDomainEvent
		{
			domainEvent.AggregateId = Id;
			domainEvent.Version = GetNewEventVersion();
			Apply(domainEvent.GetType(), domainEvent);
			appliedEvents.Add(domainEvent);
		}

		public void LoadFromHistory(IEnumerable<IDomainEvent> domainEvents)
		{
			foreach (var domainEvent in domainEvents)
			{
				Apply(domainEvent.GetType(), domainEvent);
			}

			Id = domainEvents.First().AggregateId;
			Version = domainEvents.Last().Version;
			EventVersion = Version;

		}

		private void Apply(Type eventType, IDomainEvent domainEvent)
		{
			Action<IDomainEvent> handler;

			if (!registeredEventsMap.TryGetValue(eventType, out handler))
				throw new UnregisteredDomainEventException(string.Format("The requested domain event '{0}' is not registered", eventType.FullName));

			handler(domainEvent);
		}

		public IEnumerable<IDomainEvent> GetChanges()
		{
			return appliedEvents;
		}

		public void UpdateVersion(int newVersion)
		{
			Version = newVersion;
			EventVersion = Version;
		}

		public void Clear()
		{
			appliedEvents.Clear();
		}

		private int GetNewEventVersion()
		{
			return ++EventVersion;
		}

		protected T GetRehydratedParameters<T>(IDictionary<string, object> parameters)
		{
			return DictionaryAdapterMediator.GetAdapter<T>((IDictionary)parameters);
		}
	}
}


text:
#ifndef MUMBLE_MUMBLE_USERLISTMODEL_H_
#define MUMBLE_MUMBLE_USERLISTMODEL_H_

#include <Qt>
#include <QAbstractTableModel>
#include <QDateTime>
#include <QHash>
#include <QItemSelection>
#include <QList>
#include <QModelIndex>
#include <QObject>
#include <QString>
#include <QVariant>

#include "Mumble.pb.h"

///
/// The UserListModel class provides a table model backed by a UserList protobuf structure.
/// It supports removing rows and editing user nicks.
///
class UserListModel : public QAbstractTableModel {
		Q_OBJECT
	public:
		/// Enumerates the columns in the table model
		enum Columns { COL_NICK, COL_INACTIVEDAYS, COL_LASTCHANNEL, COUNT_COL };

		 /// UserListModel constructs a table model representing the userList.
		 /// @param userList User list protobuf structure (will be copied)
		 /// @param parent Parent in QObject hierarchy
		UserListModel(const MumbleProto::UserList& userList, QObject *parent = NULL);

		int rowCount(const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE;
		int columnCount(const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE;

		QVariant headerData(int section, Qt::Orientation orientation, int role) const Q_DECL_OVERRIDE;
		QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const Q_DECL_OVERRIDE;
		bool setData(const QModelIndex &index, const QVariant &value, int role) Q_DECL_OVERRIDE;
		Qt::ItemFlags flags(const QModelIndex &index) const Q_DECL_OVERRIDE;

		bool removeRows(int row, int count, const QModelIndex &parent = QModelIndex());

		/// Function for removing all rows in a selection
		void removeRowsInSelection(const QItemSelection &selection);

		/// Returns a message for updating the original server state to the current model state.
		MumbleProto::UserList getUserListUpdate() const;

		/// Returns true if the UserList given during construction was changed.
		bool isUserListDirty() const;

		/// Returns true if the model only contains COL_NICK (true for Mumble <= 1.2.4)
		bool isLegacy() const;

	private:

		/// Given an ISO formatted UTC time string returns the number of days since then.
		/// @return QVariant() is returned for invalid strings.
		QVariant lastSeenToTodayDayCount(const std::string& lastSeenDate) const;
		/// Returns a textual representation of the channel hierarchy of the given channel
		QString pathForChannelId(const int channelId) const;
		/// Converts a ISO formatted UTC time string to a QDateTime object.
		QDateTime isoUTCToDateTime(const std::string& isoTime) const;

		typedef QList<MumbleProto::UserList_User> ModelUserList;
		/// Model backend for user data
		ModelUserList m_userList;

		typedef QHash< ::google::protobuf::uint32, MumbleProto::UserList_User> ModelUserListChangeMap;
		/// Change map indexed by user id
		ModelUserListChangeMap m_changes;

		/// True if the message given on construction lacked column data (true for murmur <= 1.2.4)
		bool m_legacyMode;

		/// Cache for lastSeenToTodayDayCount
		mutable QHash<QString, QVariant> m_stringToLastSeenToTodayCount;
		/// Cache for pathForChannelId conversions
		mutable QHash<int, QString> m_channelIdToPathMap;
};

#endif // MUMBLE_MUMBLE_USERLISTMODEL_H_


text:
@class DBTEAMPOLICIESSharedFolderMemberPolicy;

#pragma mark - API Object

///
/// The `SharedFolderMemberPolicy` union.
///
/// Policy governing who can be a member of a folder shared by a team member.
///
/// This class implements the `DBSerializable` protocol (serialize and
/// deserialize instance methods), which is required for all Obj-C SDK API route
/// objects.
///
@interface DBTEAMPOLICIESSharedFolderMemberPolicy : NSObject <DBSerializable>

#pragma mark - Instance fields

/// The `DBTEAMPOLICIESSharedFolderMemberPolicyTag` enum type represents the
/// possible tag states with which the `DBTEAMPOLICIESSharedFolderMemberPolicy`
/// union can exist.
typedef NS_ENUM(NSInteger, DBTEAMPOLICIESSharedFolderMemberPolicyTag) {
  /// Only a teammate can be a member of a folder shared by a team member.
  DBTEAMPOLICIESSharedFolderMemberPolicyTeam,

  /// Anyone can be a member of a folder shared by a team member.
  DBTEAMPOLICIESSharedFolderMemberPolicyAnyone,

  /// (no description).
  DBTEAMPOLICIESSharedFolderMemberPolicyOther,

};

/// Represents the union's current tag state.
@property (nonatomic, readonly) DBTEAMPOLICIESSharedFolderMemberPolicyTag tag;

#pragma mark - Constructors

///
/// Initializes union class with tag state of "team".
///
/// Description of the "team" tag state: Only a teammate can be a member of a
/// folder shared by a team member.
///
/// @return An initialized instance.
///
- (nonnull instancetype)initWithTeam;

///
/// Initializes union class with tag state of "anyone".
///
/// Description of the "anyone" tag state: Anyone can be a member of a folder
/// shared by a team member.
///
/// @return An initialized instance.
///
- (nonnull instancetype)initWithAnyone;

///
/// Initializes union class with tag state of "other".
///
/// @return An initialized instance.
///
- (nonnull instancetype)initWithOther;

#pragma mark - Tag state methods

///
/// Retrieves whether the union's current tag state has value "team".
///
/// @return Whether the union's current tag state has value "team".
///
- (BOOL)isTeam;

///
/// Retrieves whether the union's current tag state has value "anyone".
///
/// @return Whether the union's current tag state has value "anyone".
///
- (BOOL)isAnyone;

///
/// Retrieves whether the union's current tag state has value "other".
///
/// @return Whether the union's current tag state has value "other".
///
- (BOOL)isOther;

///
/// Retrieves string value of union's current tag state.
///
/// @return A human-readable string representing the union's current tag state.
///
- (NSString * _Nonnull)tagName;

@end

#pragma mark - Serializer Object

///
/// The serialization class for the `DBTEAMPOLICIESSharedFolderMemberPolicy`
/// union.
///
@interface DBTEAMPOLICIESSharedFolderMemberPolicySerializer : NSObject

///
/// Serializes `DBTEAMPOLICIESSharedFolderMemberPolicy` instances.
///
/// @param instance An instance of the `DBTEAMPOLICIESSharedFolderMemberPolicy`
/// API object.
///
/// @return A json-compatible dictionary representation of the
/// `DBTEAMPOLICIESSharedFolderMemberPolicy` API object.
///
+ (NSDictionary * _Nonnull)serialize:(DBTEAMPOLICIESSharedFolderMemberPolicy * _Nonnull)instance;

///
/// Deserializes `DBTEAMPOLICIESSharedFolderMemberPolicy` instances.
///
/// @param dict A json-compatible dictionary representation of the
/// `DBTEAMPOLICIESSharedFolderMemberPolicy` API object.
///
/// @return An instantiation of the `DBTEAMPOLICIESSharedFolderMemberPolicy`
/// object.
///
+ (DBTEAMPOLICIESSharedFolderMemberPolicy * _Nonnull)deserialize:(NSDictionary * _Nonnull)dict;

@end


text:
DELIMITER /
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/
INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '552','Sent when a protocol is added as a special review in an award, that will result in IRB Linking.',
'Special Review Inserted - {AWARD_NUMBER}',
'Special Review Inserted - {AWARD_NUMBER}', 'Y', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '553','Sent when a linked award is removed from the award.',
'Special Review Deleted - {AWARD_NUMBER}',
'Special Review Deleted - {AWARD_NUMBER}', 'Y', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '552'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '553'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NTFCTN_MODULE_ROLE_ID VALUES(NULL)
/

insert into NOTIFICATION_MODULE_ROLE (NOTIFICATION_MODULE_ROLE_ID, MODULE_CODE, ROLE_NAME, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MODULE_ROLE_ID), 1, 'KC-WKFLW:Unit Administrator', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NTFCTN_MDL_ROLE_QLFR_ID VALUES(NULL)
/

insert into NOTIFICATION_MDL_ROLE_QLFR (NOTIFICATION_MDL_ROLE_QLFR_ID, NOTIFICATION_MODULE_ROLE_ID, QUALIFIER, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MDL_ROLE_QLFR_ID), (SELECT (MAX(ID)) FROM SEQ_NTFCTN_MODULE_ROLE_ID) ,
'unitNumber', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NTFCTN_MODULE_ROLE_ID VALUES(NULL)
/

insert into NOTIFICATION_MODULE_ROLE (NOTIFICATION_MODULE_ROLE_ID, MODULE_CODE, ROLE_NAME, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MODULE_ROLE_ID), 1, 'KC-AWARD:Investigators', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NTFCTN_MDL_ROLE_QLFR_ID VALUES(NULL)
/

insert into NOTIFICATION_MDL_ROLE_QLFR (NOTIFICATION_MDL_ROLE_QLFR_ID, NOTIFICATION_MODULE_ROLE_ID, QUALIFIER, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MDL_ROLE_QLFR_ID), (select NOTIFICATION_MODULE_ROLE_ID from NOTIFICATION_MODULE_ROLE where MODULE_CODE = 1 and ROLE_NAME = 'KC-AWARD:Investigators'),
'award', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NTFCTN_MODULE_ROLE_ID VALUES(NULL)
/

insert into NOTIFICATION_MODULE_ROLE (NOTIFICATION_MODULE_ROLE_ID, MODULE_CODE, ROLE_NAME, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MODULE_ROLE_ID), 1, 'KC-AWARD:All Unit Administrators', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NTFCTN_MDL_ROLE_QLFR_ID VALUES(NULL)
/

insert into NOTIFICATION_MDL_ROLE_QLFR (NOTIFICATION_MDL_ROLE_QLFR_ID, NOTIFICATION_MODULE_ROLE_ID, QUALIFIER, OBJ_ID, VER_NBR, UPDATE_TIMESTAMP, UPDATE_USER)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NTFCTN_MDL_ROLE_QLFR_ID), (select NOTIFICATION_MODULE_ROLE_ID from NOTIFICATION_MODULE_ROLE where MODULE_CODE = 1 and ROLE_NAME = 'KC-AWARD:All Unit Administrators'),
'award', UUID(), 1, NOW(), 'admin')
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

-- Report Tracking Notifications
INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '401','Fiscal Report 90 days',
'Fiscal Report 90 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '401'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '402','Fiscal Report 60 days',
'Fiscal Report 60 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '402'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '403','Fiscal Report 30 days',
'Fiscal Report 30 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '403'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '404','Fiscal Report Overdue',
'Fiscal Report Overdue',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '404'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '405','Property report 90 days',
'Property report 90 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '405'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '406','Property report 60 days',
'Property report 60 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '406'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '407','Property report 30 days',
'Property report 30 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '407'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '408','Property report Overdue',
'Property report Overdue',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '408'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '409','Intellectual Property report 90 days',
'Intellectual Property report 90 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '409'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '410','Intellectual Property report 60 days',
'Intellectual Property report 60 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '410'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '411','Intellectual Property report 30 days',
'Intellectual Property report 30 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '411'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '412','Intellectual Property report Overdue',
'Intellectual Property report Overdue',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '412'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '413','Technical management report 90 days',
'Technical management report 90 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '413'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '414','Technical management report 60 days',
'Technical management report 60 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '414'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '415','Technical management report 30 days',
'Technical management report 30 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '415'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '416','Technical management report Overdue',
'Technical management report Overdue',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '416'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '417','Procurement report 90 days',
'Procurement report 90 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '417'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '418','Procurement report 60 days',
'Procurement report 60 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '418'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '419','Procurement report 30 days',
'Procurement report 30 days',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '419'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE (NOTIFICATION_TYPE_ID, MODULE_CODE, ACTION_CODE, DESCRIPTION, SUBJECT, MESSAGE, PROMPT_USER, SEND_NOTIFICATION, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), 1, '420','Procurement report Overdue',
'Procurement report Overdue',
'

Award Number	Sponsor	Sponsor Award Number	Award Title	PI	Unit	Account Number	Report Type	Due Date
{BEGIN_REPEAT_SECTION}
{AWARD_NUMBER}	{SPONSOR_NAME}	{SPONSOR_AWARD_NUMBER}	{AWARD_TITLE}	{PI_NAME}	{LEAD_UNIT_NAME}	{ACCOUNT_NUMBER}	{REPORT_TYPE}	{REPORT_DUE_DATE}
{END_REPEAT_SECTION}
', 'N', 'Y', 'admin', NOW(), 1, UUID())
/
INSERT INTO SEQ_NOTIFICATION_TYPE_ID VALUES(NULL)
/

INSERT INTO NOTIFICATION_TYPE_RECIPIENT (NOTIFICATION_TYPE_RECIPIENT_ID, NOTIFICATION_TYPE_ID, ROLE_NAME, ROLE_SUB_QUALIFIER, UPDATE_USER, UPDATE_TIMESTAMP, VER_NBR, OBJ_ID)
VALUES ((SELECT (MAX(ID)) FROM SEQ_NOTIFICATION_TYPE_ID), (select NOTIFICATION_TYPE_ID from notification_type where MODULE_CODE = 1 and ACTION_CODE = '420'), 'KC-WKFLW:Unit Administrator',
'2', 'admin', NOW(), 1, UUID())
/
DELIMITER ;


text:
package com.mntone.toastnotificationbridgemod.data;

import com.google.gson.annotations.SerializedName;

public final class ChatMessage
{
	@SerializedName("player_name")
	private String _playerName;

	@SerializedName("text")
	private String _text;

	@SerializedName("skin_data")
	private String _skinData;

	public ChatMessage(final String playerName, final String text)
	{
		this._playerName = playerName;
		this._text = text;
		this._skinData = null;
	}

	public ChatMessage(final String playerName, final String text, final String skinData)
	{
		this._playerName = playerName;
		this._text = text;
		this._skinData = skinData;
	}

	public String getPlayerName()
	{
		return this._playerName;
	}

	public void setPlayerName(final String playerName)
	{
		this._playerName = playerName;
	}

	public String getText()
	{
		return this._text;
	}

	public void setText(final String text)
	{
		this._text = text;
	}

	public String getSkinData()
	{
		return this._skinData;
	}

	public void setSkinData(final String skinData)
	{
		this._skinData = skinData;
	}
}


text:
#include "FrictionContactProblem.h"
#include <assert.h>             // for assert
#include <math.h>               // for fabs
#include <stdio.h>              // for printf, fprintf, fscanf, NULL, fclose
#include <stdlib.h>             // for malloc, free, exit, EXIT_FAILURE
#include <sys/errno.h>          // for errno
#include <string.h>             // for memcpy
#include "SiconosBlas.h"        // for cblas_dscal
#include "NumericsMatrix.h"     // for NumericsMatrix, NM_create, RawNumeric...
#include "SparseBlockMatrix.h"  // for SBM_extract_component_3x3
//#define DEBUG_STDOUT
//#define DEBUG_MESSAGES
#include "debug.h"              // for DEBUG_PRINT, DEBUG_PRINTF
#include "numerics_verbose.h"   // for CHECK_IO, numerics_error, numerics_pr...
#include "io_tools.h"
#if defined(WITH_FCLIB)
#include "fclib_interface.h"
#endif

void frictionContact_display(FrictionContactProblem* problem)
{

  assert(problem);
  int n = problem->dimension * problem->numberOfContacts;
  printf("FrictionContact Display :\n-------------\n");
  printf("dimension :%d \n", problem->dimension);
  printf("numberOfContacts:%d \n", problem->numberOfContacts);

  if(problem->M)
  {
    printf("M matrix:\n");
    NM_display(problem->M);
  }
  else
    printf("No M matrix:\n");

  if(problem->q)
  {
    printf("q vector:\n");
    NM_vector_display(problem->q,n);
  }
  else
    printf("No q vector:\n");

  if(problem->mu)
  {
    printf("mu vector:\n");
    NM_vector_display(problem->mu,problem->numberOfContacts);
  }
  else
    printf("No mu vector:\n");

}

int frictionContact_printInFile(FrictionContactProblem*  problem, FILE* file)
{
  if(! problem)
  {
    fprintf(stderr, "Numerics, FrictionContactProblem printInFile failed, NULL input.\n");
    exit(EXIT_FAILURE);
  }
  int i;

  int d  = problem->dimension;
  fprintf(file, "%d\n", d);
  int nc = problem->numberOfContacts;
  fprintf(file, "%d\n", nc);
  NM_write_in_file(problem->M, file);
  for(i = 0; i < problem->M->size1; i++)
  {
    fprintf(file, "%32.24e ", problem->q[i]);
  }
  fprintf(file, "\n");
  for(i = 0; i < nc; i++)
  {
    fprintf(file, "%32.24e ", problem->mu[i]);
  }
  fprintf(file, "\n");
  return 0;
}

int frictionContact_printInFilename(FrictionContactProblem* problem, char* filename)
{
  int info = 0;
  FILE * file = fopen(filename, "w");

  if(!file)
  {
    return errno;
  }

  info = frictionContact_printInFile(problem, file);

  fclose(file);
  return info;
}

FrictionContactProblem *  frictionContact_newFromFile(FILE* file)
{

  FrictionContactProblem* problem = frictionContactProblem_new();
  assert(file);
  DEBUG_PRINT("Start -- int frictionContact_newFromFile(FrictionContactProblem* problem, FILE* file)\n");
  int nc = 0, d = 0;
  int i;
  CHECK_IO(fscanf(file, "%d\n", &d));
  problem->dimension = d;
  DEBUG_PRINTF("problem->dimension = %i \n",problem->dimension);
  CHECK_IO(fscanf(file, "%d\n", &nc));
  problem->numberOfContacts = nc;
  problem->M =  NM_new_from_file(file);

  problem->q = (double *) malloc(problem->M->size1 * sizeof(double));
  for(i = 0; i < problem->M->size1; i++)
  {
    CHECK_IO(fscanf(file, "%lf ", &(problem->q[i])));
  }

  problem->mu = (double *) malloc(nc * sizeof(double));
  for(i = 0; i < nc; i++)
  {
    CHECK_IO(fscanf(file, "%lf ", &(problem->mu[i])));
  }
  DEBUG_PRINT("End --  int frictionContact_newFromFile(FrictionContactProblem* problem, FILE* file)\n");

  return problem;
}

FrictionContactProblem * frictionContact_new_from_filename(const char* filename)
{

  FrictionContactProblem* problem = NULL;
  int is_hdf5 = check_hdf5_file(filename);
  // if the input file is an hdf5 file, we try to read it with fclib interface function.
  if(is_hdf5)
  {
#if defined(WITH_FCLIB)
    problem = frictionContact_fclib_read(filename);
#else
    numerics_error("FrictionContactProblem",
                   "Try to read an hdf5 file, while fclib interface is not active. Recompile Siconos with fclib.",
                   filename);
#endif
  }
  else
  {
    FILE * file = fopen(filename, "r");
    if(!file)
      numerics_error("FrictionContactProblem", "Can not open file ", filename);

    problem = frictionContact_newFromFile(file);
    fclose(file);
  }
  return problem;

}

void frictionContactProblem_free(FrictionContactProblem* problem)
{
  assert(problem);
  if(problem->M)
  {
    NM_clear(problem->M);
    free(problem->M);
    problem->M = NULL;
  }

  if(problem->mu)
  {
    free(problem->mu);
    problem->mu = NULL;
  }

  if(problem->q)
  {
    free(problem->q);
    problem->q = NULL;
  }

  free(problem);

}

FrictionContactProblem* frictionContactProblem_new(void)
{
  FrictionContactProblem* fcp = (FrictionContactProblem*) malloc(sizeof(FrictionContactProblem));
  fcp->dimension = 0;
  fcp->numberOfContacts = 0;
  fcp->M = NULL;
  fcp->q = NULL;
  fcp->mu = NULL;

  return fcp;
}

FrictionContactProblem* frictionContactProblem_new_with_data(int dim, int nc, NumericsMatrix* M, double* q, double* mu)
{
  FrictionContactProblem* fcp = (FrictionContactProblem*) malloc(sizeof(FrictionContactProblem));

  fcp->dimension = dim;
  fcp->numberOfContacts = nc;
  fcp->M = M;
  fcp->q = q;
  fcp->mu = mu;

  return fcp;
}

//#define SN_SBM_TO_DENSE

void createSplittedFrictionContactProblem(FrictionContactProblem* problem,  SplittedFrictionContactProblem * splitted_problem)
{
  /* Number of contacts */
  int nc = problem->numberOfContacts;

  splitted_problem->fc3d = problem;

  /* Splitting vector q */

  splitted_problem->q_n = (double *) malloc(nc * sizeof(double));
  splitted_problem->q_t = (double *) malloc(2* nc * sizeof(double));

  for(int contact = 0 ; contact < nc; contact ++)
  {
    splitted_problem->q_n[contact] = problem->q[contact*3];
    splitted_problem->q_t[2*contact] = problem->q[contact*3+1];
    splitted_problem->q_t[2*contact+1] = problem->q[contact*3+2];
  }

  /* Splitting matrix M */

  int storageType = problem->M->storageType;
  NumericsMatrix * M =  problem->M;

  splitted_problem->M_nn =  NM_create(problem->M->storageType, nc, nc);
  splitted_problem->M_nt =  NM_create(problem->M->storageType, nc, 2*nc);
  splitted_problem->M_tn =  NM_create(problem->M->storageType, 2*nc, nc);
  splitted_problem->M_tt =  NM_create(problem->M->storageType, 2*nc, 2*nc);

  NumericsMatrix * M_nn =  splitted_problem->M_nn;
  NumericsMatrix * M_tn =  splitted_problem->M_tn;
  NumericsMatrix * M_nt =  splitted_problem->M_nt;
  NumericsMatrix * M_tt =  splitted_problem->M_tt;

  switch(storageType)
  {
  case NM_SPARSE_BLOCK:
  {
    DEBUG_PRINT("NM_SPARSE_BLOCK case\n");
    unsigned int row_components_nn[1] = {0};
    unsigned int row_components_size_nn =1;
    unsigned int col_components_nn[1] = {0};
    unsigned int col_components_size_nn =1;
    SBM_extract_component_3x3(M->matrix1, M_nn->matrix1,
                              row_components_nn, row_components_size_nn, col_components_nn, col_components_size_nn);

    unsigned int row_components_nt[1] = {0};
    unsigned int row_components_size_nt =1;
    unsigned int col_components_nt[2] = {1,2};
    unsigned int col_components_size_nt =2;
    SBM_extract_component_3x3(M->matrix1, M_nt->matrix1,
                              row_components_nt, row_components_size_nt, col_components_nt, col_components_size_nt);

    unsigned int row_components_tn[2] = {1,2};
    unsigned int row_components_size_tn =2;
    unsigned int col_components_tn[1] = {0};
    unsigned int col_components_size_tn =1;
    SBM_extract_component_3x3(M->matrix1, M_tn->matrix1,
                              row_components_tn, row_components_size_tn, col_components_tn, col_components_size_tn);

    unsigned int row_components_tt[2] = {1,2};
    unsigned int row_components_size_tt =2;
    unsigned int col_components_tt[2] = {1,2};
    unsigned int col_components_size_tt =2;
    SBM_extract_component_3x3(M->matrix1, M_tt->matrix1,
                              row_components_tt, row_components_size_tt, col_components_tt, col_components_size_tt);

#ifdef SN_SBM_TO_DENSE
    M_nn->matrix0 =(double *)malloc(M_nn->size0*M_nn->size1*sizeof(double));
    SBM_to_dense(M_nn->matrix1, M_nn->matrix0);
    M_nn->storageType=NM_DENSE;
    M_nt->matrix0 =(double *)malloc(M_nt->size0*M_nt->size1*sizeof(double));
    SBM_to_dense(M_nt->matrix1, M_nt->matrix0);
    M_nt->storageType=NM_DENSE;
    M_tn->matrix0 =(double *)malloc(M_tn->size0*M_tn->size1*sizeof(double));
    SBM_to_dense(M_tn->matrix1, M_tn->matrix0);
    M_tn->storageType=NM_DENSE;
    M_tt->matrix0 =(double *)malloc(M_tt->size0*M_tt->size1*sizeof(double));
    SBM_to_dense(M_tt->matrix1, M_tt->matrix0);
    M_tt->storageType=NM_DENSE;
#endif

    break;
  }
  default:
    numerics_error("createSplittedFrictionContactProblem", "storageType value %d not implemented yet !", storageType);
  }

}
void frictionContactProblem_compute_statistics(FrictionContactProblem* problem,
    double * reaction,
    double * velocity,

    double tol,
    int do_print)
{
  /* NumericsMatrix* M = problem->M; */
  /* double* q = problem->q; */
  double* mu = problem->mu;

  /* Number of contacts */
  int nc = problem->numberOfContacts;
  /* int n = problem->M->size0; */
  /* int m = 3 * nc; */

  int contact =0, pos =0;

  int take_off_count=0;
  int closed_count=0;

  int sticking_count=0;
  int sliding_count=0;
  int ambiguous_take_off_count=0;
  int ambiguous_closed_count=0;

  for(contact =0; contact < nc; contact ++)
  {
    pos=contact*3;
    if(velocity[pos] > tol)
    {
      take_off_count++;
      if(fabs(reaction[pos]) > tol)
        ambiguous_take_off_count++;
    }
    else if(reaction[pos] > tol)
    {
      closed_count++;
      if(fabs(velocity[pos]) > tol)
        ambiguous_closed_count++;

      double criteria = reaction[pos+1]*reaction[pos+1] + reaction[pos+2]*reaction[pos+2] - mu[contact]*mu[contact]*reaction[pos]*reaction[pos];
      if(criteria < 0)
      {
        sticking_count++;
      }
      else
      {
        sliding_count++;
      }
    }
  }

  numerics_printf_verbose(do_print, "---- FC3D - STAT  - Number of contact = %i\t,  take off = %i\t, closed = %i\t, sliding = %i\t,sticking = %i\t, ambiguous take off = %i\t, ambiguous closed = %i",nc,take_off_count,closed_count,sliding_count,sticking_count, ambiguous_take_off_count,ambiguous_closed_count);

}

FrictionContactProblem* frictionContact_copy(FrictionContactProblem* problem)
{
  assert(problem);

  int nc = problem->numberOfContacts;
  int n = problem->M->size0;
  FrictionContactProblem* new = (FrictionContactProblem*) malloc(sizeof(FrictionContactProblem));
  new->dimension = problem->dimension;
  new->numberOfContacts = problem->numberOfContacts;
  new->M = NM_new();
  NM_copy(problem->M, new->M);
  new->q = (double*)malloc(n*sizeof(double));
  memcpy(new->q, problem->q, n*sizeof(double));
  new->mu = (double*)malloc(nc*sizeof(double));
  memcpy(new->mu, problem->mu, nc*sizeof(double));
  return new;
}

void frictionContact_rescaling(
  FrictionContactProblem* problem,
  double alpha,
  double gamma)
{
  int n = problem->M->size0;
  /* scaling of M */
  NM_scal(alpha*gamma*gamma, problem->M);
  /* scaling of q */
  cblas_dscal(n,alpha*gamma,problem->q,1);

}


text:
use std::libc::c_int;

use std::io::IoResult;
use std::clone::Clone;
use std::io::net::ip::SocketAddr;
use std::io::{Reader, Writer, Listener, Acceptor};
use std::io::IoResult;
use std::rt::rtio::{IoFactory, LocalIo, RtioSocket, RtioTcpListener};
use std::rt::rtio::{RtioTcpAcceptor, RtioTcpStream};

/// An asynchronous reader.
pub trait AsyncReader {
    fn async_read(&mut self, output: &mut [u8]) -> IoResult<uint>;
}

/// An asynchronous writer.
pub trait AsyncWriter {
    fn async_write(&mut self, input: &[u8]) -> IoResult<uint>;
}

pub trait AsyncListener<T, A: Acceptor<T>> {
    fn listen(self) -> IoResult<A>;
}

pub trait AsyncAcceptor<T> {
    fn accept(&mut self) -> IoResult<T>;
}