text:
from __future__ import unicode_literals

from django.db import migrations, models

class Migration(migrations.Migration):

    dependencies = [
        ('questions', '0002_question_label'),
        ('workout_programs', '0013_auto_20170323_0217'),
    ]

    operations = [
        migrations.RemoveField(
            model_name='program',
            name='experience_for',
        ),
        migrations.RemoveField(
            model_name='program',
            name='gender_for',
        ),
        migrations.RemoveField(
            model_name='program',
            name='goal_for',
        ),
        migrations.RemoveField(
            model_name='program',
            name='length_for',
        ),
        migrations.RemoveField(
            model_name='program',
            name='per_week_for',
        ),
        migrations.RemoveField(
            model_name='workout',
            name='experience_for',
        ),
        migrations.RemoveField(
            model_name='workout',
            name='gender_for',
        ),
        migrations.RemoveField(
            model_name='workout',
            name='goal_for',
        ),
        migrations.AddField(
            model_name='program',
            name='tags',
            field=models.ManyToManyField(to='questions.Answer'),
        ),
        migrations.AddField(
            model_name='workout',
            name='tags',
            field=models.ManyToManyField(to='questions.Answer'),
        ),
    ]

redpajama_set_name: RedPajamaGithub


text:
package com.smcplugin.psi;

import java.util.List;
import org.jetbrains.annotations.*;
import com.intellij.psi.PsiElement;

public interface SmcGenericParameter extends PsiElement {

  @NotNull
  SmcParameterType getParameterType();

}


text:
Changelog
=========

v0.3.0
------
- Bumped Quill.js to v0.2.0
- Exposed `focus` and `blur` public methods from component.
- Exposed `getEditor` public method to retrieve the backing Quill instance from the component.
- Added callbacks for listening to keyboard events.
- Added tooltips for toolbar choice controls (@bird512).
- Added support for child nodes in toolbar items (@1000hz).
- Added support for custom formats in the configuration (@csk157).
- Added an option to disable the toolbar entirely by passing `false` to `toolbar`.
- Added an option to disable styles entirely by passing `false` to `style` (@kkerr1).
- Fixed an issue where the Quill would duplicate React IDs inside the toolbar leading to errors. Fixes #15.
- Fixes an issue where the editor could be used while null (@brucedlukens).
- Fixes an issue where null would be set on the editor. Fixes #48.
- Fixes an issue where the editor would be instantiated with the wrong value. Fixes #50.
- Avoiding parsing Quill's `dist` directory with webpack.

v0.2.2
------
- Added missing `modules` propType and documentation.
- Children are now cloned so ReactQuill can own their refs. Fixes #20.

v0.2.1
------
- Link toolbar button and module are now enabled by default. Fixes #19.

v0.2.0
------
- Fix React warnings about unique `key` props in toolbar (@Janekk).
- Sending `delta` and `source` from editor change events. Fixes #17.
- Rewritten uncontrolled and semi-controlled operation. Should fix #9, #10 and #14.
- Editor props can now be changed after mounting.
- Added callback for selection change event. Closes #12.

v0.1.1
------
- The pre-compiled distributable is not shipped with the NPM package anymore. Should fix #2.
- Sourcemaps are now emitted for both distributables, as separate files.
- Avoiding parsing Quill as it ships with a pre-built main.

v0.1.0
------
- Added support for toolbar separators.
- Added support for font family selectors.
- Updated the default toolbar to match Quill's.
- Updated Quill to v0.19.12.

v0.0.6
------
- Added keywords for inclusion in [React.parts](https://react.parts).

v0.0.5
------
- Default empty content for components with no value.
- Fixes wrong `QuillToolbar` propType.

v0.0.4
------
- Added color toggle to toolbar (@chrismcv)
- Exporting default item sets on `QuillToolbar`
- Fixed `QuillComponent` only accepting a single child.

v0.0.3
------
- Switched from `quilljs` package to `quill`.
- Using the new `destroy()` from Quill.

v0.0.2
------
- Compatible with React 0.12.

v0.0.1
------
- Initial version.


text:
import { navigate, withPrefix } from 'gatsby';
import { LocalStorage } from './src/utils/local-storage';
import supportedFrameworks from './src/utils/supported-frameworks.js';
import 'jquery/dist/jquery.min.js';
import 'popper.js/dist/popper.min.js';
import 'bootstrap/dist/js/bootstrap.min.js';
import '@fortawesome/fontawesome-svg-core/styles.css';
import './src/bootstrap.scss';
import './src/themes/prism-coy-without-shadows.css';
import 'fontsource-roboto';

const frameworkStorageKey = 'framework';
const getRelativePath = path => path.replace(withPrefix('/'), '/');

export const onRouteUpdate = ({ location }) => {
    if (getRelativePath(location.pathname) === '/') {
        const selectedFramework = LocalStorage.get(frameworkStorageKey) || 'javascript';

        navigate(`/${selectedFramework}/`, { replace: true });
    } else if (LocalStorage.exists()) {
        const frameworkFromUrl = getRelativePath(location.pathname).split('/').filter(p => p !== '')[0];

        if (frameworkFromUrl && supportedFrameworks.indexOf(frameworkFromUrl) >= 0) {
            LocalStorage.set(frameworkStorageKey, frameworkFromUrl);
        }
    }
};


text:
    typedef enum {
        Clean=0, Dirty=1
    } FreeTag;

    typedef struct DNode_ {
        FreeTag refFreeTag; // Broadcast to all memory refs of any freeing of memory.
        void *data;
        void (*dataDestroyer)(void *);
        struct DNode_ *prev, *next;
    } DNode;

    inline DNode *allocDNode(void);

    DNode *newDNode(void *);
    DNode *destroyDNode(DNode *);
    DNode *destroyLoneDNode(DNode *dn);
    DNode *appendDNode(DNode *cur, void *data);
    DNode *prependDNode(DNode *cur, void *data);
    DNode *prependDNodeDestroyer(DNode *cur, void *data, void (*freer)(void *));

    unsigned int isCircular(DNode *dn);
#endif // _DNODE_H


text:
/**
 * The Sprite Animation Restart Event.
 *
 * This event is dispatched by a Sprite when an animation restarts playing on it.
 *
 * Listen for it on the Sprite using `sprite.on('animationrestart', listener)`
 *
 * This same event is dispatched for all animations. To listen for a specific animation, use the `SPRITE_ANIMATION_KEY_RESTART` event.
 *
 * @event Phaser.Animations.Events#SPRITE_ANIMATION_RESTART
 * @since 3.16.1
 *
 * @param {Phaser.Animations.Animation} animation - A reference to the Animation that was restarted on the Sprite.
 * @param {Phaser.Animations.AnimationFrame} frame - The current Animation Frame that the Animation restarted with.
 * @param {Phaser.GameObjects.Sprite} gameObject - A reference to the Game Object on which the animation restarted playing.
 */
module.exports = 'animationrestart';


text:
package main

import (
	"github.com/spf13/cobra"
)

// toolboxCmd represents the toolbox command
var toolboxCmd = &cobra.Command{
	Use:   "toolbox",
	Short: "Misc infrequently used commands",
}

func init() {
	rootCommand.AddCommand(toolboxCmd)
}


text:
local DB = require("app.libs.db")
local db = DB:new()

local comment_model = {}

function comment_model:delete(user_id, comment_id)
    local res, err = db:query("delete from comment where id=? and user_id=?",
            {tonumber(comment_id), tonumber(user_id)})
    if res and not err then
    	return true
    else
    	return false
    end
end

function comment_model:new(topic_id,  user_id, content)
    return db:query("insert into comment(topic_id,user_id, content) values(?,?,?)",
            {tonumber(topic_id), tonumber(user_id), content})
end

function comment_model:query(comment_id)
	comment_id = tonumber(comment_id)
	if not comment_id or comment_id == 0 then
		return {}
	end

	local res, err = db:query("select c.*, u.avatar as avatar, u.username as user_name from comment c " ..
		" left join user u on c.user_id=u.id " ..
		" where c.id=?",
		{comment_id})

	if not res or err or type(res) ~= "table" or #res <= 0 then
		return {}
	else
		return res[1]
	end
end

function comment_model:get_all_of_user(user_id, page_no, page_size)
	page_no = tonumber(page_no)
	page_size = tonumber(page_size)
	if page_no < 1 then
		page_no = 1
	end
	local res, err = db:query("select t.id as topic_id, t.title as topic_title, c.content as comment_content,c.id as comment_id, c.create_time as comment_time from comment c" ..
		" right join topic t on c.topic_id=t.id" ..
		" where c.user_id=? order by c.id desc limit ?,?",
		{tonumber(user_id), (page_no - 1) * page_size, page_size})

	if not res or err or type(res) ~= "table" or #res <= 0 then
		return {}
	else
		return res
	end
end

function comment_model:get_total_count_of_user(user_id)
	local res, err = db:query("select count(c.id) as comment_count from comment c " ..
		" right join topic t on c.topic_id=t.id" ..
		" where c.user_id=?", {tonumber(user_id)})

	if err or not res or #res~=1 or not res[1].comment_count then
   		return 0
   	else
   		return res[1].comment_count
   	end
end

function comment_model:get_total_count()
	local res, err = db:query("select count(c.id) as comment_count from comment c ")

	if err or not res or #res~=1 or not res[1].comment_count then
   		return 0
   	else
   		return res[1].comment_count
   	end
end

function comment_model:get_total_count_of_topic(topic_id)
	topic_id = tonumber(topic_id)
	if not topic_id or topic_id == 0 then
		return 0
	end

	local res, err = db:query("select count(id) as c from comment where topic_id=?", {topic_id})

	if err or not res or #res~=1 or not res[1].c then
   		return 0
   	else
   		return res[1].c
   	end
end

function comment_model:get_all_of_topic(topic_id, page_no, page_size)
	topic_id = tonumber(topic_id)
	if not topic_id or topic_id == 0 then
		return 0
	end

	page_no = tonumber(page_no)
	page_size = tonumber(page_size)
	if page_no < 1 then
		page_no = 1
	end
	local res, err = db:query("select c.*, u.avatar as avatar, u.username as user_name from comment c " ..
		" left join user u on c.user_id=u.id " ..
		" where c.topic_id=? order by c.id asc limit ?,?",
		{topic_id, (page_no - 1) * page_size, page_size})

	if not res or err or type(res) ~= "table" or #res <= 0 then
		return {}
	else
		return res
	end
end

function comment_model:reset_topic_comment_num(topic_id)
	db:query("update topic set reply_num=(select count(id) from comment where topic_id=?) where id=?",
		{tonumber(topic_id), tonumber(topic_id)})
end

return comment_model


text:
package com.lab.epam.command.logination.google;

import com.google.api.client.auth.oauth2.Credential;
import com.google.api.client.googleapis.auth.oauth2.GoogleAuthorizationCodeFlow;
import com.google.api.client.googleapis.auth.oauth2.GoogleAuthorizationCodeRequestUrl;
import com.google.api.client.googleapis.auth.oauth2.GoogleTokenResponse;
import com.google.api.client.http.GenericUrl;
import com.google.api.client.http.HttpRequest;
import com.google.api.client.http.HttpRequestFactory;
import com.google.api.client.http.HttpTransport;
import com.google.api.client.http.javanet.NetHttpTransport;
import com.google.api.client.json.JsonFactory;
import com.google.api.client.json.jackson2.JacksonFactory;

import java.io.IOException;
import java.security.SecureRandom;
import java.util.Arrays;
import java.util.Collection;

/**
 * Created by Dima on 14-Jul-15.
 */
public class GoogleAuthCommand {
    /**
     * Please provide a value for the CLIENT_ID constant before proceeding, set this up at https://code.google.com/apis/console/
     */
    private static final String CLIENT_ID = "871789124358-opb9ilvbac4ps320hi22g8jqu9t0iua3.apps.googleusercontent.com";
    /**
     * Please provide a value for the CLIENT_SECRET constant before proceeding, set this up at https://code.google.com/apis/console/
     */
    private static final String CLIENT_SECRET = "avxzlsjlQwjhQEHG-G9pp16j";

    /**
     * Callback URI that google will redirect to after successful authentication
     */
    private static final String CALLBACK_URI = "http://localhost:8080";

    // start google authentication constants
    private static final Iterable<String> SCOPE = Arrays.asList("https://www.googleapis.com/auth/userinfo.profile;https://www.googleapis.com/auth/userinfo.email".split(";"));
    private static final String USER_INFO_URL = "https://www.googleapis.com/oauth2/v1/userinfo";
    private static final JsonFactory JSON_FACTORY = new JacksonFactory();
    private static final HttpTransport HTTP_TRANSPORT = new NetHttpTransport();
    // end google authentication constants

    private String stateToken;

    private final GoogleAuthorizationCodeFlow flow;

    /**
     * Constructor initializes the Google Authorization Code Flow with CLIENT ID, SECRET, and SCOPE
     */
    public GoogleAuthCommand() {
        flow = new GoogleAuthorizationCodeFlow.Builder(HTTP_TRANSPORT,
                JSON_FACTORY, CLIENT_ID, CLIENT_SECRET, (Collection<String>) SCOPE).build();
        generateStateToken();
    }

    /**
     * Builds a login URL based on client ID, secret, callback URI, and scope
     */
    public String buildLoginUrl() {

        final GoogleAuthorizationCodeRequestUrl url = flow.newAuthorizationUrl();

        return url.setRedirectUri(CALLBACK_URI).setState(stateToken).build();
    }

    /**
     * Generates a secure state token
     */
    private void generateStateToken() {

        SecureRandom sr1 = new SecureRandom();

        stateToken = "google;" + sr1.nextInt();

    }

    /**
     * Accessor for state token
     */
    public String getStateToken() {
        return stateToken;
    }

    /**
     * Expects an Authentication Code, and makes an authenticated request for the user's profile information
     *
     * @param authCode authentication code provided by google
     * @return JSON formatted user profile information
     */
    public String getUserInfoJson(final String authCode) throws IOException {

        final GoogleTokenResponse response = flow.newTokenRequest(authCode).setRedirectUri(CALLBACK_URI).execute();
        final Credential credential = flow.createAndStoreCredential(response, null);
        final HttpRequestFactory requestFactory = HTTP_TRANSPORT.createRequestFactory(credential);
        // Make an authenticated request
        final GenericUrl url = new GenericUrl(USER_INFO_URL);
        final HttpRequest request = requestFactory.buildGetRequest(url);
        request.getHeaders().setContentType("application/json");
        final String jsonIdentity = request.execute().parseAsString();
        System.out.println(jsonIdentity);
        return jsonIdentity;
    }
}


text:
from azure import (
    DEFAULT_HTTP_TIMEOUT,
    MANAGEMENT_HOST,
    _str,
    )
from azure.servicemanagement import (
    WebSpaces,
    WebSpace,
    Sites,
    Site,
    MetricResponses,
    MetricDefinitions,
    PublishData,
    _XmlSerializer,
    )
from azure.servicemanagement.servicemanagementclient import (
    _ServiceManagementClient,
    )

class WebsiteManagementService(_ServiceManagementClient):
    ''' Note that this class is a preliminary work on WebSite
        management. Since it lack a lot a features, final version
        can be slightly different from the current one.
    '''

    def __init__(self, subscription_id=None, cert_file=None,
                 host=MANAGEMENT_HOST, request_session=None,
                 timeout=DEFAULT_HTTP_TIMEOUT):
        '''
        Initializes the website management service.

        subscription_id:
            Subscription to manage.
        cert_file:
            Path to .pem certificate file (httplib), or location of the
            certificate in your Personal certificate store (winhttp) in the
            CURRENT_USER\my\CertificateName format.
            If a request_session is specified, then this is unused.
        host:
            Live ServiceClient URL. Defaults to Azure public cloud.
        request_session:
            Session object to use for http requests. If this is specified, it
            replaces the default use of httplib or winhttp. Also, the cert_file
            parameter is unused when a session is passed in.
            The session object handles authentication, and as such can support
            multiple types of authentication: .pem certificate, oauth.
            For example, you can pass in a Session instance from the requests
            library. To use .pem certificate authentication with requests
            library, set the path to the .pem file on the session.cert
            attribute.
        timeout:
            Optional. Timeout for the http request, in seconds.
        '''
        super(WebsiteManagementService, self).__init__(
            subscription_id, cert_file, host, request_session, timeout)

    #--Operations for web sites ----------------------------------------
    def list_webspaces(self):
        '''
        List the webspaces defined on the account.
        '''
        return self._perform_get(self._get_list_webspaces_path(),
                                 WebSpaces)

    def get_webspace(self, webspace_name):
        '''
        Get details of a specific webspace.

        webspace_name:
            The name of the webspace.
        '''
        return self._perform_get(self._get_webspace_details_path(webspace_name),
                                 WebSpace)

    def list_sites(self, webspace_name):
        '''
        List the web sites defined on this webspace.

        webspace_name:
            The name of the webspace.
        '''
        return self._perform_get(self._get_sites_path(webspace_name),
                                 Sites)

    def get_site(self, webspace_name, website_name):
        '''
        List the web sites defined on this webspace.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        '''
        return self._perform_get(self._get_sites_details_path(webspace_name,
                                                              website_name),
                                 Site)

    def create_site(self, webspace_name, website_name, geo_region, host_names,
                    plan='VirtualDedicatedPlan', compute_mode='Shared',
                    server_farm=None, site_mode=None):
        '''
        Create a website.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        geo_region:
            The geographical region of the webspace that will be created.
        host_names:
            An array of fully qualified domain names for website. Only one
            hostname can be specified in the azurewebsites.net domain.
            The hostname should match the name of the website. Custom domains
            can only be specified for Shared or Standard websites.
        plan:
            This value must be 'VirtualDedicatedPlan'.
        compute_mode:
            This value should be 'Shared' for the Free or Paid Shared
            offerings, or 'Dedicated' for the Standard offering. The default
            value is 'Shared'. If you set it to 'Dedicated', you must specify
            a value for the server_farm parameter.
        server_farm:
            The name of the Server Farm associated with this website. This is
            a required value for Standard mode.
        site_mode:
            Can be None, 'Limited' or 'Basic'. This value is 'Limited' for the
            Free offering, and 'Basic' for the Paid Shared offering. Standard
            mode does not use the site_mode parameter; it uses the compute_mode
            parameter.
        '''
        xml = _XmlSerializer.create_website_to_xml(webspace_name, website_name, geo_region, plan, host_names, compute_mode, server_farm, site_mode)
        return self._perform_post(
            self._get_sites_path(webspace_name),
            xml,
            Site)

    def delete_site(self, webspace_name, website_name,
                    delete_empty_server_farm=False, delete_metrics=False):
        '''
        Delete a website.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        delete_empty_server_farm:
            If the site being deleted is the last web site in a server farm,
            you can delete the server farm by setting this to True.
        delete_metrics:
            To also delete the metrics for the site that you are deleting, you
            can set this to True.
        '''
        path = self._get_sites_details_path(webspace_name, website_name)
        query = ''
        if delete_empty_server_farm:
            query += '&deleteEmptyServerFarm=true'
        if delete_metrics:
            query += '&deleteMetrics=true'
        if query:
            path = path + '?' + query.lstrip('&')
        return self._perform_delete(path)

    def update_site(self, webspace_name, website_name, state=None):
        '''
        Update a web site.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        state:
            The wanted state ('Running' or 'Stopped' accepted)
        '''
        xml = _XmlSerializer.update_website_to_xml(state)
        return self._perform_put(
            self._get_sites_details_path(webspace_name, website_name),
            xml, async=True)

    def restart_site(self, webspace_name, website_name):
        '''
        Restart a web site.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        '''
        return self._perform_post(
            self._get_restart_path(webspace_name, website_name),
            None, async=True)

    def get_historical_usage_metrics(self, webspace_name, website_name,
                                     metrics = None, start_time=None, end_time=None, time_grain=None):
        '''
        Get historical usage metrics.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        metrics:
            Optional. List of metrics name. Otherwise, all metrics returned.
        start_time:
            Optional. An ISO8601 date. Otherwise, current hour is used.
        end_time:
            Optional. An ISO8601 date. Otherwise, current time is used.
        time_grain:
            Optional. A rollup name, as P1D. OTherwise, default rollup for the metrics is used.
        More information and metrics name at:
        http://msdn.microsoft.com/en-us/library/azure/dn166964.aspx
        '''
        metrics = ('names='+','.join(metrics)) if metrics else ''
        start_time = ('StartTime='+start_time) if start_time else ''
        end_time = ('EndTime='+end_time) if end_time else ''
        time_grain = ('TimeGrain='+time_grain) if time_grain else ''
        parameters = ('&'.join(v for v in (metrics, start_time, end_time, time_grain) if v))
        parameters = '?'+parameters if parameters else ''
        return self._perform_get(self._get_historical_usage_metrics_path(webspace_name, website_name) + parameters,
                                 MetricResponses)

    def get_metric_definitions(self, webspace_name, website_name):
        '''
        Get metric definitions of metrics available of this web site.

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        '''
        return self._perform_get(self._get_metric_definitions_path(webspace_name, website_name),
                                 MetricDefinitions)

    def get_publish_profile_xml(self, webspace_name, website_name):
        '''
        Get a site's publish profile as a string

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        '''
        return self._perform_get(self._get_publishxml_path(webspace_name, website_name),
                                 None).body.decode("utf-8")

    def get_publish_profile(self, webspace_name, website_name):
        '''
        Get a site's publish profile as an object

        webspace_name:
            The name of the webspace.
        website_name:
            The name of the website.
        '''
        return self._perform_get(self._get_publishxml_path(webspace_name, website_name),
                                 PublishData)

    #--Helper functions --------------------------------------------------
    def _get_list_webspaces_path(self):
        return self._get_path('services/webspaces', None)

    def _get_webspace_details_path(self, webspace_name):
        return self._get_path('services/webspaces/', webspace_name)

    def _get_sites_path(self, webspace_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites'

    def _get_sites_details_path(self, webspace_name, website_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites/' + _str(website_name)

    def _get_restart_path(self, webspace_name, website_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites/' + _str(website_name) + '/restart/'

    def _get_historical_usage_metrics_path(self, webspace_name, website_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites/' + _str(website_name) + '/metrics/'

    def _get_metric_definitions_path(self, webspace_name, website_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites/' + _str(website_name) + '/metricdefinitions/'

    def _get_publishxml_path(self, webspace_name, website_name):
        return self._get_path('services/webspaces/',
                              webspace_name) + '/sites/' + _str(website_name) + '/publishxml/'


text:
<?php
namespace Foo;

interface Bar
{
}


text:
package models.domain

trait HoneyPot {
}


text:
using namespace acmacs::argv;
struct Options : public argv
{
    Options(int a_argc, const char* const a_argv[], on_error on_err = on_error::exit) : argv() { parse(a_argc, a_argv, on_err); }

    argument<str> color1{*this, arg_name{"color1"}, mandatory};
    argument<str> color2{*this, arg_name{"color2"}, mandatory};
    argument<str> color3{*this, arg_name{"color3"}, mandatory};
    argument<size_t> output_size{*this, arg_name{"output-size"}, mandatory};
};

int main(int argc, const char* argv[])
{
    int exit_code = 0;

    try {
        Options opt(argc, argv);
        const Color c1{*opt.color1}, c2{*opt.color2}, c3{*opt.color3};
        const auto result = acmacs::color::bezier_gradient(c1, c2, c3, opt.output_size);
        for (const auto& color : result)
            fmt::print("{:X}\n", color);
    }
    catch (std::exception& err) {
        fmt::print(stderr, "ERROR: {}\n", err);
        exit_code = 1;
    }

    return exit_code;
}

// ----------------------------------------------------------------------
/// Local Variables:
/// eval: (if (fboundp 'eu-rename-buffer) (eu-rename-buffer))
/// End:


text:
export Pull from './Pull';
export PullRight from './PullRight';
export PullLeft from './PullLeft';


text:
package au.com.breakpoint.hedron.daogen;

import java.util.ArrayList;
import java.util.List;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import au.com.breakpoint.hedron.core.context.ThreadContext;
import au.com.breakpoint.hedron.daogen.Util.EnumString;

public class Constraint
{
    public Constraint ()
    {
    }

    Constraint (final Node node)
    {
        // First get the attributes of our own node.
        getAttributes (node);

        final NodeList childNodes = node.getChildNodes ();

        for (int i = 0; i < childNodes.getLength (); ++i)
        {
            final Node childNode = childNodes.item (i);

            if (childNode.getNodeType () == Node.ELEMENT_NODE)
            {
                final String nodeName = childNode.getNodeName ();
                if (nodeName.equals ("column"))
                {
                    m_columns.add (new Column (null, childNode));
                }
                else
                {
                    ThreadContext.assertError (false, "[%s] unknown option element [%s]", getClass ().getSimpleName (),
                        nodeName);
                }
            }
        }
    }

    public List<Column> getColumns ()
    {
        return m_columns;
    }

    public String getName ()
    {
        return m_name;
    }

    public ConstraintType getType ()
    {
        return m_type;
    }

    public void setName (final String name)
    {
        m_name = name;
    }

    public void setType (final ConstraintType type)
    {
        m_type = type;
    }

    private void getAttributes (final Node node)
    {
        final AttributeSet attributeSet = new AttributeSet (node);

        m_name = attributeSet.getAttributeString ("name", null);
        m_type = attributeSet.getAttributeEnum ("type", m_typeEnumStrings);

        ThreadContext.assertError (m_name != null, "<constraint> must have a 'name' attribute");

        attributeSet.validate (); // look for any unsupported attributes
    }

    public enum ConstraintType
    {
        Check, ForeignKey, Index, PrimaryKey, Uniqueness;
    }

    private final List<Column> m_columns = new ArrayList<Column> ();

    private String m_name;

    private ConstraintType m_type; // constraint type

    private static final EnumString[] m_typeEnumStrings = new EnumString[]
    {
            new EnumString (ConstraintType.PrimaryKey, "compoundprimarykey"),
            new EnumString (ConstraintType.ForeignKey, "compoundforeignkey"),
            new EnumString (ConstraintType.Uniqueness, "uniqueness"),
            new EnumString (ConstraintType.Check, "check"),
            new EnumString (ConstraintType.Index, "index")
    };
}


text:
package org.jiucai.appframework.base.plugin;

public class AuthException extends Exception {

	private static final long serialVersionUID = 2281209444559988755L;

}


text:
A web part for use in Microsoft Teams that displays a mashup of information partaining to customer visits. Visits are obtained from the Team's shared calendar and displayed by user. When a visit is selected, the solution displays:
 * customer information (from the Northwind database)
 * documents (from SharePoint)
 * recent transactions (mock)
 * a map (Bing maps)
 * current weather (Open Weather Map)
 * photos (from SharePoint)
 * a text box for sending messages to the Teams channel with deep links back to the selected visit

The solution demonstrates:

 * A Teams tab using SharePoint Framework
 * Accessing the hosting Team using the teams context and the Graph API
 * Deep linking to a SharePoint Framework tab
 * A mashup using React components

![Field Visit Demo](./documentation/FieldVisitDemo.png)

## Compatibility

![SPFx 1.8](https://img.shields.io/badge/SPFx-1.8.0-green.svg)
![Node.js v8](https://img.shields.io/badge/Node.js-v8-green.svg)
![Compatible with SharePoint Online](https://img.shields.io/badge/SharePoint%20Online-Compatible-green.svg)
![Does not work with SharePoint 2019](https://img.shields.io/badge/SharePoint%20Server%202019-Incompatible-red.svg)
![Does not work with SharePoint 2016 (Feature Pack 2)](https://img.shields.io/badge/SharePoint%20Server%202016%20(Feature%20Pack%202)-Incompatible-red.svg "SharePoint Server 2016 Feature Pack 2 requires SPFx 1.1")
![Local Workbench Compatible](https://img.shields.io/badge/Local%20Workbench-Compatible-green.svg)
![Hosted Workbench Compatible](https://img.shields.io/badge/Hosted%20Workbench-Compatible-green.svg)
![Compatible with Remote Containers](https://img.shields.io/badge/Remote%20Containers-Compatible-green.svg)

## Applies to

* [SharePoint Framework Developer](https://docs.microsoft.com/sharepoint/dev/spfx/sharepoint-framework-overview)
* [Building Microsoft Teams Tabs using SharePoint Framework](https://docs.microsoft.com/en-us/sharepoint/dev/spfx/integrate-with-teams-introduction)
* [Office 365 developer tenant](https://docs.microsoft.com/sharepoint/dev/spfx/set-up-your-developer-tenant)

## Solution

Solution|Author(s)
--------|---------
field-visit-demo-tab | [Bob German](https://github.com/BobGerman) ([@Bob1German](http://www.twitter.com/Bob1German))

Many thanks to [Arbindo Chattopadhyay](https://www.linkedin.com/in/arbindoc/) for writing the [detailed installation instructions ](./documentation/setup.md) and compiling [links to resources](./documentation/resources.md).

## Version history

Version|Date|Comments
-------|----|--------
1.1|April 20, 2019|Updated for SPFx 1.8, moved to sp-dev-fx-webparts
1.0|April 5, 2019|Initial release

## Minimal Path to Awesome

The quickest path to building the web part and running it with mock data:

>  This sample can also be opened with [VS Code Remote Development](https://code.visualstudio.com/docs/remote/remote-overview). Visit https://aka.ms/spfx-devcontainer for further instructions.

 * Obtain API keys for [Bing Maps](https://docs.microsoft.com/en-us/bingmaps/getting-started/bing-maps-dev-center-help/getting-a-bing-maps-key) and [Open Weather Maps](https://openweathermap.org/api). In src/webparts/fieldVisitTab/, copy constants.sample.ts to constants.ts and add the API keys.
 * npm install
 * gulp serve

To work with real data, the web part requires content to be in place including:

* A Microsoft Team
* Calendar items in the Team's shared calendar, encoded with Northwind database customer IDs
* Documents and photos in SharePoint

[Detailed setup instructions are here](./documentation/setup.md).

## Help

We do not support samples, but this community is always willing to help, and we want to improve these samples. We use GitHub to track issues, which makes it easy for  community members to volunteer their time and help resolve issues.

If you're having issues building the solution, please run [spfx doctor](https://pnp.github.io/cli-microsoft365/cmd/spfx/spfx-doctor/) from within the solution folder to diagnose incompatibility issues with your environment.

You can try looking at [issues related to this sample](https://github.com/pnp/sp-dev-fx-webparts/issues?q=label%3A%22sample%3A%20react-teams-tab-field-visit-mashup%22) to see if anybody else is having the same issues.

You can also try looking at [discussions related to this sample](https://github.com/pnp/sp-dev-fx-webparts/discussions?discussions_q=react-teams-tab-field-visit-mashup) and see what the community is saying.

If you encounter any issues while using this sample, [create a new issue](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Abug-suspected%2Csample%3A%20react-teams-tab-field-visit-mashup&template=bug-report.yml&sample=react-teams-tab-field-visit-mashup&authors=@BobGerman&title=react-teams-tab-field-visit-mashup%20-%20).

For questions regarding this sample, [create a new question](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aquestion%2Csample%3A%20react-teams-tab-field-visit-mashup&template=question.yml&sample=react-teams-tab-field-visit-mashup&authors=@BobGerman&title=react-teams-tab-field-visit-mashup%20-%20).

Finally, if you have an idea for improvement, [make a suggestion](https://github.com/pnp/sp-dev-fx-webparts/issues/new?assignees=&labels=Needs%3A+Triage+%3Amag%3A%2Ctype%3Aenhancement%2Csample%3A%20react-teams-tab-field-visit-mashup&template=suggestion.yml&sample=react-teams-tab-field-visit-mashup&authors=@BobGerman&title=react-teams-tab-field-visit-mashup%20-%20).

## Disclaimer

**THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.**

<img src="https://pnptelemetry.azurewebsites.net/sp-dev-fx-webparts/samples/react-teams-tab-field-visit-mashup" />


text:
function testJackknife(numtest, MCS, obs)
  inform("Start testing Jackknife / $obs")

  nsigma = 3
  counts = zeros(Int, nsigma)

  for itest in 1:numtest
    sobs = obs()
    for mcs in 1:MCS
      sobs << randn()
    end
    jk = jackknife(sobs)

    @test_approx_eq_eps mean(sobs) mean(jk) 1.0e-10
    @test_approx_eq_eps stderror(sobs) stderror(jk) 1.0e-10
  end
  inform("Success testing Jackknife / $obs")
end

testJackknife(1_000, 8192, SimpleObservable)
testJackknife(1_000, 8192, BinningObservable)


text:
A Java interface that is used to expose OSGi services.

Although serivce interfaces and implementations should normally be in separate bundles, this bundle also
exposes an implementation of the interface as a service.


text:
require 'spec_helper'

describe Raemon::Configuration do
  describe '#option' do
    before(:all) do
      described_class.option(:test_setting, :default => true)
    end

    it "creates a getter for an option" do
      described_class.should respond_to(:test_setting)
    end

    it "creates a setter for the option" do
      described_class.should respond_to(:test_setting=)
    end

    it "creates a conditional for the option" do
      described_class.should respond_to(:test_setting?)
    end

    it "allows the setting of a default value" do
      described_class.test_setting.should == true
    end
  end

  its(:server_name) { should == described_class::DEFAULT_SERVER_NAME }

  its(:detach) { should == described_class::DEFAULT_DETACH }

  its(:num_workers) { should == described_class::DEFAULT_NUM_WORKERS }

  its(:worker_class) { should be_nil }

  its(:timeout) { should == described_class::DEFAULT_TIMEOUT }

  its(:env) { should == described_class::DEFAULT_ENVIRONMENT }

  its(:memory_limit) { should == described_class::DEFAULT_MEMORY_LIMIT_IN_MEGABYTES }

  its(:logger) { should be_a(Logger) }

  its(:instrumentor) { should be_nil }

  its(:instrumentor_name) { should eq(described_class::DEFAULT_INSTRUMENTOR_NAME) }

  its(:on_stop) { should be_a(Proc) }

  describe '.logger=' do
    let(:fake_logger) { double }

    it 'sets the logger' do
      described_class.logger = fake_logger
      described_class.logger.should == fake_logger
    end
  end

  describe '.root=' do
    it 'sets the root location of the project' do
      described_class.root = '.'
      described_class.root.to_s.should == File.expand_path('.')
    end
  end

  describe '.root' do
    it 'is a Pathname' do
      described_class.root.should be_a(Pathname)
    end

    it 'raises an exception when not set' do
      expect {
        described_class.root = nil
        described_class.root
      }.to raise_error(StandardError, 'Raemon::Config.root must be set')
    end
  end
end


text:
import Dates from "../../data/dates/dates";
import PaDetailsGet from "../paDetails/paDetailsGet";
import dbPaBills from "../../db/dbPaBills";
import dbPaDetailBills from "../../db/dbPaDetailBills";
import dbPaDetails from "../../db/dbPaDetails";
import dbResidents from "../../db/dbResidents";
import dbSessions from "../../db/dbSessions";
import dbTxnPaBills from "../../db/dbTxnPaBills";

const fromDailyOrContinuation = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  det.ElectricityCharges = bill.ElectricityCharges;
  det.Miscellaneous = bill.Miscellaneous;
  det.DevelopmentFund = bill.HalfYearly;
  return det;
};

const fromElectricityBill = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  det.ElectricityCharges = bill.ElectricityCharges;
  return det;
};

const fromNightStayOrFineWarden = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  det.Miscellaneous = bill.Miscellaneous;
  return det;
};

const fromPhdHraBill = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  const multiplier = bill.Miscellaneous / 4800;
  det.DevelopmentFund = multiplier * 500;
  det.RutineHstlMaintnceCharges = multiplier * 4300;
  return det;
};

const fromSecurityBill = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  det.Security = bill.Security;
  return det;
};

const fromRegularBill = async args => {
  const det = await dbPaDetails.getDefault();
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  det.RoomRent = bill.RoomRent;
  det.WaterCharges = bill.WaterCharges;
  det.ElectricityCharges = bill.ElectricityCharges;
  det.Miscellaneous = bill.Miscellaneous;
  const sess = await dbSessions.getCurrentSession();
  const hySixMonths = sess.DevelopmentFund + sess.RutineHstlMaintnceCharges;
  const hyThreeMonths = hySixMonths / 2;
  if (bill.HalfYearly === hySixMonths) {
    det.DevelopmentFund = sess.DevelopmentFund;
    det.RutineHstlMaintnceCharges = sess.RutineHstlMaintnceCharges;
  } else if (bill.HalfYearly === hyThreeMonths) {
    det.DevelopmentFund = sess.DevelopmentFund / 2;
    det.RutineHstlMaintnceCharges = sess.RutineHstlMaintnceCharges / 2;
  }
  return det;
};

const getDetail = async args => {
  let det = {};
  switch (args.billType) {
    case "Daily":
      det = await fromDailyOrContinuation(args);
      break;
    case "Regular":
      det = await fromRegularBill(args);
      break;
    case "Electricity":
      det = await fromElectricityBill(args);
      break;
    case "NightStay":
      det = await fromNightStayOrFineWarden(args);
      break;
    case "FineWarden":
      det = await fromNightStayOrFineWarden(args);
      break;
    case "Continuation":
      det = await fromDailyOrContinuation(args);
      break;
    case "PhdHra":
      det = await fromPhdHraBill(args);
      break;
    case "Security":
      det = await fromSecurityBill(args);
      break;
    case "HalfYearly":
      det = await fromRegularBill(args);
      break;
    case "Quarterly":
      det = await fromRegularBill(args);
      break;
    default:
      console.log("Default: Get Pa Detail");
  }
  return det;
};

const insert = async (detail, bill, resId) => {
  const ef = await Dates.effectiveDate();
  const rNum = await PaDetailsGet.nextReceiptNumber();
  const res = await dbResidents.getById(resId);
  const det = Object.assign({}, detail);
  det.ReceiptDate = ef.EffectiveDate;
  det.DepositDate = ef.EffectiveDate;
  det.ResidentId = resId;
  det.ReceiptNumber = rNum;
  det.Name = res.Name;
  det.RoomNumber = res.Room.Value;
  det.RollNumber = res.RollNumber;
  det.Focus = true;
  det.Total = bill.Total;
  await dbPaDetails.insert(det);
  const defBill = await dbPaDetailBills.getDefault();
  defBill.DetailId = det._id;
  defBill.ResidentId = resId;
  defBill.BillPeriod = bill.BillPeriod;
  defBill.Type = bill.Type;
  defBill.Security = bill.Security;
  defBill.RoomRent = bill.RoomRent;
  defBill.WaterCharges = bill.WaterCharges;
  defBill.ElectricityCharges = bill.ElectricityCharges;
  defBill.Miscellaneous = bill.Miscellaneous;
  defBill.HalfYearly = bill.HalfYearly;
  defBill.StartDate = bill.StartDate;
  defBill.EndDate = bill.EndDate;
  defBill.Total = bill.Total;
  await dbPaDetailBills.insert(defBill);
  await dbPaBills.removePaBill(resId, bill);
  return det._id;
};

const createDetail = async args => {
  const det = await getDetail(args);
  const bill = await dbPaBills.getBillForResident(args.resId, args.billId);
  const id = await insert(det, bill, args.resId);
  return id;
};

const detailMultipleBills = async (args, paBills) => {
  const res = await dbResidents.getById(args.resId);
  const nArgs = Object.assign({}, args);
  const det = await dbPaDetails.getDefault();
  const detArray = [];
  const defBillArray = [];
  for (const bill of paBills) {
    nArgs.billType = bill.Type;
    nArgs.billId = bill._id;
    const nDet = await getDetail(nArgs);
    detArray.push(nDet);
    const defBill = await dbPaDetailBills.getDefault();
    defBill.DetailId = det._id;
    defBill.ResidentId = nArgs.resId;
    defBill.BillPeriod = bill.BillPeriod;
    defBill.Type = bill.Type;
    defBill.Security = bill.Security;
    defBill.RoomRent = bill.RoomRent;
    defBill.WaterCharges = bill.WaterCharges;
    defBill.ElectricityCharges = bill.ElectricityCharges;
    defBill.Miscellaneous = bill.Miscellaneous;
    defBill.HalfYearly = bill.HalfYearly;
    defBill.StartDate = bill.StartDate;
    defBill.EndDate = bill.EndDate;
    defBill.Total = bill.Total;
    defBillArray.push(defBill);
  }
  let element = {};
  for (const detail of detArray) {
    element = detail;
    det.Security += element.Security;
    det.RoomRent += element.RoomRent;
    det.WaterCharges += element.WaterCharges;
    det.ElectricityCharges += element.ElectricityCharges;
    det.Miscellaneous += element.Miscellaneous;
    det.DevelopmentFund += element.DevelopmentFund;
    det.CelebrationFund += element.CelebrationFund;
    det.RutineHstlMaintnceCharges += element.RutineHstlMaintnceCharges;
    det.Total +=
      element.Security +
      element.RoomRent +
      element.WaterCharges +
      element.ElectricityCharges +
      element.Miscellaneous +
      element.DevelopmentFund +
      element.CelebrationFund +
      element.RutineHstlMaintnceCharges;
  }
  const ef = await Dates.effectiveDate();
  const rNum = await PaDetailsGet.nextReceiptNumber();
  det.ReceiptDate = ef.EffectiveDate;
  det.DepositDate = ef.EffectiveDate;
  det.ResidentId = args.resId;
  det.ReceiptNumber = rNum;
  det.Name = res.Name;
  det.RoomNumber = res.Room.Value;
  det.RollNumber = res.RollNumber;
  det.Focus = true;
  for (const bill of defBillArray) {
    await dbPaDetailBills.insert(bill);
  }
  for (const bill of paBills) {
    await dbPaBills.removePaBill(args.resId, bill);
  }
  await dbPaDetails.insert(det);
  return det._id;
};

const createDetailAllBills = async args => {
  const paBills = await dbPaBills.getAll(args.resId);
  const id = await detailMultipleBills(args, paBills);
  return id;
};

const txnDetailPa = async args => {
  const bills = await dbTxnPaBills.getAll(args.resId);
  const id = await detailMultipleBills(args, bills);
  await dbTxnPaBills.removeAll(args.resId);
  return id;
};

const PaDetailBills = {
  txnDetailPa,
  createDetailAllBills,
  createDetail
};

export default PaDetailBills;


text:
package ru.shadam.tarantool.core;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.tarantool.SocketChannelProvider;

import java.io.IOException;
import java.net.InetSocketAddress;
import java.nio.channels.SocketChannel;

/**
 * @author sala
 */
public class SimpleSocketChannelProvider implements SocketChannelProvider {
    private static final Logger logger = LoggerFactory.getLogger(SimpleSocketChannelProvider.class);

    private final String host;
    private final int port;

    public SimpleSocketChannelProvider(String host, int port) {
        this.host = host;
        this.port = port;
    }

    @Override
    public SocketChannel get(int retryNumber, Throwable lastError) {
        if(lastError != null) {
            logger.error(lastError.getMessage(), lastError);
        }
        try {
            return SocketChannel.open(new InetSocketAddress(host, port));
        } catch (IOException e) {
            throw new IllegalStateException(e.getMessage(), e);
        }
    }
}


text:
var StatusService = require('../service/statusService');

module.exports = function(app, opts) {
  var service = new StatusService(app, opts);
  app.set('statusService', service, true);
  service.name = '__status__';
  return service;
};


text: @Deprecated() <caret>


text:
<!DOCTYPE html>

  <meta charset="utf-8">

  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>{{ league_info['name'] }}</title>
  <meta name="description" content="NewsUp is a multi-page oriented template perfect for NewsUp - News, Magazine, Blogging and Article Directory.">
  <meta name="keywords" content="news theme, magazine, blog, article directory, article submission, writer, author, publication, html, bootstrap">
  <meta name="author" content="Sempy Themes">

  <link rel="stylesheet" href="{{ static_url('weui/lib/weui.min.css') }}">
  <link rel="stylesheet" href="{{ static_url('weui/css/jquery-weui.css') }}">
  <link rel="shortcut icon" href="/static/newsup/img/favicon.ico" type="image/x-icon">
  <link rel="apple-touch-icon" href="/static/newsup/img/apple-touch-icon.png">
  <link rel="apple-touch-icon" sizes="72x72" href="/static/newsup/img/apple-touch-icon-72x72.png">
  <link rel="apple-touch-icon" sizes="114x114" href="/static/newsup/img/apple-touch-icon-114x114.png">

  <link href="{{ static_url('newsup/css/bootstrap.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/bootstrap-tagsinput.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/jasny-bootstrap.min.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('css/font-awesome.min.css') }}" rel="stylesheet" type="text/css" />

  <link href="{{ static_url('newsup/css/effect2.css') }}" rel='stylesheet' type='text/css' />
  <link href="{{ static_url('newsup/css/animate.css') }}" rel='stylesheet' type='text/css' />

  <link href="{{ static_url('newsup/js/fancybox/jquery.fancybox.css') }}" media="screen" rel="stylesheet" type="text/css" />

  <link href="{{ static_url('newsup/css/owl.carousel.css') }}" media="screen" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/owl.theme.css') }}" media="screen" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/owl.transitions.css') }}" media="screen" rel="stylesheet" type="text/css" />

  <link href="{{ static_url('newsup/css/rs-wp-v1.2.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/jquery.rs.selectbox.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('css/style.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/css/responsive.css') }}" rel="stylesheet" type="text/css" />
  <link href="{{ static_url('newsup/fonts/stylesheet.css') }}" rel="stylesheet" type="text/css" />

      {% module Template("newsup/block-socialbar.html", is_login=is_login) %}

      {% module Template("newsup/block-menubar.html", league_info=league_info) %}

            Home
            >
            Author

John Doe

                Reporter, blogger

                   +48 122 33 66
                   john@gmail.com

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam porttitor urna eget lectus ultrices, sed euismod nulla congue. Aliquam aliquet malesuada nulla, a malesuada orci ornare eget. Aenean nunc ante, fringilla in elementum ut, sagittis
              ac arcu. Aliquam et mollis diam. Etiam eros nisl, dignissim eget eros vel, laoreet euismod justo.

News

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  fitness

                  fitness

Lorem ipsum dolor sit amet, Ut congue ex eget nulla lacinia.

                  <time>12 sep, 2015</time>

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut congue ex eget nulla lacinia, id efficitur felis luctus. Nam vitae dui id ex faucibus tincidunt id non eros. Pellentesque varius dapibus lacinia. Quisque eu arcu efficitur nibh
                    hendrerit pulvinar sed quis nunc.

                  Prev
                  1
                  2
                  3
                  4
                  5
                  Next

            {% module Template("newsup/block-widget-social.html") %}

            {% module Template("newsup/block-widget-popular.html", populars=populars, news=news) %}

            {% module Template("newsup/block-widget-adv.html", activities=activities) %}

            {% module Template("newsup/block-widget-video.html") %}

            {% module Template("newsup/block-widget-contactus.html") %}

    {% module Template("newsup/block-lastest-comments.html", lastest_comments=lastest_comments) %}

    {% module Template("newsup/block-footer.html") %}


text:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<title>IDelegateDTO</title>
<meta name="date" content="2014-01-15">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">

JavaScript is disabled on your browser.

Skip navigation links

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev Class

Next Class

Frames

No Frames

All Classes

Summary:

Nested |

Field |

Constr |

Method

Detail:

Field |

Constr |

Method

org.quickstart.api.message

Interface IDelegateDTO<A,M>

Type Parameters:

A - defines the basic message type

M - defines the basic message type

public interface IDelegateDTO<A,M>

DTO interface to transfer messages to desired target in different perspective.

Author:

Andy Moncsek

Method Summary

All Methods Instance Methods Abstract Methods

Modifier and Type
Method and Description

Message<A,M>
getMessage()

Returns the message.

java.lang.String
getTarget()

Get the target id to transfer to.

boolean
isPerspective()

returns true when message target is a perspective.

Method Detail

getTarget

java.lang.String getTarget()

Get the target id to transfer to.

Returns:

targetId

getMessage

Message<A,M> getMessage()

Returns the message.

Returns:

the message

isPerspective

boolean isPerspective()

returns true when message target is a perspective.

Returns:

true when target is perspective.

Skip navigation links

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev Class

Next Class

Frames

No Frames

All Classes

Summary:

Nested |

Field |

Constr |

Method

Detail:

Field |

Constr |

Method