text:
class Proposal
  include Mongoid::Document
  include Mongoid::Timestamps
  include AASM
  include Badger
  include BelongsToLang

  belongs_to :wordset
  belongs_to :user
  belongs_to :project

  has_many :votes,
            dependent: :destroy

  define_model_callbacks :proposal_committed

  field :state, type: String, as: "s"
  field :reason, type: String, as: "r"
  field :wordnet, type: Boolean, default: false, as: "wn"
  field :tally, type: Integer, default: 0
  field :flagged_value, type: Integer, default: 0
  field :original, type: Hash
  field :word_name, type: String, as: "w", default: ""

  field :vote_user_ids, type: Array

  # Having a note is special, it means that the
  # system did something, and it disables certain
  # normal events, like pusher, etc.
  field :note, type: String, as: "note"

  field :edited_at, type: Time, default: lambda { Time.now }

  before_create :cache_word_name!

  after_create :vote_on_it!
  after_create :create_initial_activity!

  badge do
    base_levels [1, 5, 10, 25, 50]
    on :after_proposal_committed
    value do |model|
      model.user.proposals.where(state: "accepted").count
    end
  end

  validates :user,
            :associated => true
  validates :lang,
            :presence => true

  index({wordset_id: 1, state: 1})
  index({wordset_id: 1, created_at: -1})
  index({user_id: 1})
  index({user_id: 1, state: 1})
  index({user_id: 1, created_at: -1})
  index({created_at: -1})
  index({vote_user_ids: 1, state: 1})
  index({_type: 1})
  index({state: 1})
  index({state: 1, created_at: -1, _id: 1})

  aasm :column => :state do
    state :open, initial: true
    state :accepted
    state :rejected
    state :flagged
    state :withdrawn

    event :approve, after: :commit_proposal! do
      transitions from: :open, to: :accepted
    end

    event :reject, after: :cleanup_proposal! do
      transitions from: :open, to: :rejected
    end

    event :flag, after: :cleanup_proposal! do
      transitions from: :open, to: :flagged
    end

    event :withdraw, after: :cleanup_proposal! do
      transitions from: :open, to: :withdrawn
    end

  end

  def pushUpdate!
    if note.blank?
      Pusher['proposals'].trigger('push',
        ProposalSerializer.new(self).to_json)
    end
  end

  def vote_on_it!
    if self.user
      Vote.create(proposal: self, user: user, yae: true, autovote: true)
    end
  end

  def commit_proposal!
    if valid?
      run_callbacks :proposal_committed do
        commit!
        create_final_activity!
        if user

          if project
            give_project_badge!
          end
          user.recalculate_points!
          user.save
        end
      end
    end
  end

  def give_project_badge!
    user.badges.find_or_create_by(project: project, subject: "projects", name: project.slug)
  end

  # Call this if the user just did an edit and
  # you want to reset everything.
  def finished_edit!
    self.edited_at = Time.now
    self.votes.where(:autovote.ne => true).each do |v|
      v.update_attributes(usurped: true)
    end
    EditProposalActivity.create(user: self.user,
                                proposal: self)
    recalculate_tally!
  end

  def cleanup_proposal!
    create_final_activity!
  end

  def recalculate_tally
    vote_list = votes.where(:usurped => false, :withdrawn.in => [false, nil])
    self.vote_user_ids = votes.pluck :user_id
    self.tally = vote_list.sum(:value)
    self.tally = 100 if self.tally > 100
    self.tally = -100 if self.tally < -100
    self.flagged_value = votes.where(flagged: true).sum(:value)
  end

  def recalculate_tally!
    recalculate_tally
    if self.open?
      if self.flagged_value <= -50
        flag!
      elsif self.tally >= 100
        approve!
      elsif self.tally <= -100
        reject!
      end
    end
    self.save
  end

  def create_initial_activity!
    if self.user
      NewProposalActivity.create(user: self.user, proposal: self)
    end
  end

  def create_final_activity!
    if note.blank? && !flagged?
      ProposalClosedActivity.create(user: self.user, proposal: self, final_state: self.state)
    end
    self.votes.each &:proposal_just_closed! #Make sure we trigger recalculating votes
  end

  def activities
    Activity.where(proposal_id: self.id)
  end

  def cache_word_name!
    if wordset
      self.word_name = wordset.name
    end
  end

end


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace BudzetDomowy.Models
{
    public abstract class Entry
    {
        public DateTime Date {get; set;}
        public string Name { get; set; }

    }
}

redpajama_set_name: RedPajamaGithub


text:
var apply_rule = function (str, rule) {
    str = str.replace(new RegExp(rule.match/*, "g"*/), rule.replace);
    return str;
};

exports.worker = function (task, config) {

    var input = JSON.parse(task.config.input);

    var str = input._INPUT;

    input.RULE.forEach(function (rule) {
        str = apply_rule(str, rule);
    });

    task.respondCompleted({
        _OUTPUT: str
    });

};


text: module.exports = require('requirejs')('tiles');


text:
rm reports/*.report
lua test.lua $*


text:
        <meta charset='UTF-8' />
        <title>cube game</title>
        <link rel="stylesheet" href="style.css">
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
        <link rel="shortcut icon" href="./img/favicon.ico">
        <link rel="apple-touch-icon" sizes="57x57" href="./img/apple-touch-icon-57x57.png">
        <link rel="apple-touch-icon" sizes="114x114" href="./img/apple-touch-icon-114x114.png">
        <link rel="apple-touch-icon" sizes="72x72" href="./img/apple-touch-icon-72x72.png">
        <link rel="apple-touch-icon" sizes="144x144" href="./img/apple-touch-icon-144x144.png">
        <link rel="apple-touch-icon" sizes="60x60" href="./img/apple-touch-icon-60x60.png">
        <link rel="apple-touch-icon" sizes="120x120" href="./img/apple-touch-icon-120x120.png">
        <link rel="apple-touch-icon" sizes="76x76" href="./img/apple-touch-icon-76x76.png">
        <link rel="apple-touch-icon" sizes="152x152" href="./img/apple-touch-icon-152x152.png">
        <link rel="icon" type="image/png" href="./img/favicon-196x196.png" sizes="196x196">
        <link rel="icon" type="image/png" href="./img/favicon-160x160.png" sizes="160x160">
        <link rel="icon" type="image/png" href="./img/favicon-96x96.png" sizes="96x96">
        <link rel="icon" type="image/png" href="./img/favicon-16x16.png" sizes="16x16">
        <link rel="icon" type="image/png" href="./img/favicon-32x32.png" sizes="32x32">
        <meta name="msapplication-TileColor" content="#2b5797">
        <meta name="msapplication-TileImage" content="./img/mstile-144x144.png">
        <meta name="msapplication-config" content="./img/browserconfig.xml">

#cubegame

0

front 0 = top 0
do ↑ or ↑ to combine them.
top will increase 0 → 1
and front will get random 0 → ?

front 2 ≠ right 1
do → or → to rotate cube.
They will not change, but cube will rotate

Once you combine sides, you get points
as much as you get on increased side
You can see score on bottom left corner of screen.


text:
require "carrierwave"
require "carrierwave/optimize_image"
require "carrierwave/optimize_image/image_optimizer"


text:
hunterfood_spider
=================

HunterFood é um aplicativo criado durante a realização do TCC do IFSP - Campus Guarulhos.
hunterfood_spider é um web crawler criado em java usando como exemplo o web crawler criado no artigo da revista MundoJ disponivel em http://www.mundoj.com.br/codigos.shtml


text:
#include <string.h>
#include "os_heap.h"
#include "DataWriter.h"
#include "Constants.h"
#include "QosUtils.h"
#include "StatusUtils.h"
#include "MiscUtils.h"
#include "StatusUtils.h"
#include "ReportUtils.h"
#include "SequenceUtils.h"
#include "dds_builtinTopicsSplDcps.h"

#include "u_observable.h"

using namespace DDS::OpenSplice::Utils;

DDS::OpenSplice::DataWriter::DataWriter () :
    DDS::OpenSplice::Entity (DATAWRITER),
    publisher(NULL),
    topic(NULL)
{
    // Do nothing.
}

DDS::OpenSplice::DataWriter::~DataWriter ()
{
    // Delegate to parent.
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::nlReq_init (
    DDS::OpenSplice::Publisher *publisher,
    const DDS::DataWriterQos &qos,
    DDS::OpenSplice::Topic *a_topic,
    const char *name)
{
    DDS::ReturnCode_t result = DDS::RETCODE_OK;
    u_writerQos uWriterQos = NULL;
    u_writer uWriter = NULL;

    assert (publisher != NULL);
    /* Only check for QoS consistency here in debug builds. It's unnecessary to
       to verify it twice in release builds. */
    assert (DDS::OpenSplice::Utils::qosIsConsistent (qos) == DDS::RETCODE_OK);
    assert (a_topic != NULL);
    assert (name != NULL);

    uWriterQos = u_writerQosNew (NULL);
    if (uWriterQos == NULL) {
        result = DDS::RETCODE_OUT_OF_RESOURCES;
        CPP_REPORT(result, "Could not copy DataWriterQos.");
    } else {
        result = DDS::OpenSplice::Utils::copyQosIn (qos, uWriterQos);
    }

    if (result == DDS::RETCODE_OK) {
        result = a_topic->write_lock ();
    }

    if (result == DDS::RETCODE_OK) {
        uWriter = u_writerNew (
            u_publisher (publisher->rlReq_get_user_entity ()),
            name,
            u_topic (a_topic->rlReq_get_user_entity ()),
            uWriterQos);
        if (!uWriter) {
            result = DDS::RETCODE_OUT_OF_RESOURCES;
            CPP_REPORT(result, "Could not create DataWriter.");
        }

        if (result == DDS::RETCODE_OK) {
            result = DDS::OpenSplice::Entity::nlReq_init (u_entity (uWriter));
            if (result == DDS::RETCODE_OK) {
                (void) DDS::Publisher::_duplicate(publisher);
                this->publisher = publisher;
                (void) DDS::Topic::_duplicate(a_topic);
                this->topic = a_topic;
                a_topic->wlReq_incrNrUsers();
                setDomainId(publisher->getDomainId());
            }
        }

        a_topic->unlock ();
    }

    if (uWriterQos) {
        u_writerQosFree (uWriterQos);
    }

    return result;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::wlReq_deinit ()
{
    DDS::ReturnCode_t result;

    this->disable_callbacks();

    if (this->topic != NULL) {
        result = this->topic->write_lock();
        if (result == DDS::RETCODE_OK) {
            this->topic->wlReq_decrNrUsers();
            this->topic->unlock();
        } else {
            CPP_PANIC("Could not lock Topic.");
        }
        DDS::release (this->topic);
        this->topic = NULL;
    }
    if (this->publisher != NULL) {
        DDS::release (this->publisher);
        this->publisher = NULL;
    }
    result = DDS::OpenSplice::Entity::wlReq_deinit();

    return result;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::set_qos (
    const DDS::DataWriterQos &qos
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    DDS::DataWriterQos writerQos;
    DDS::TopicQos topicQos;
    u_writer uWriter;
    u_writerQos uWriterQos = NULL;
    u_result uResult;

    CPP_REPORT_STACK();

    result = DDS::OpenSplice::Utils::qosIsConsistent (qos);

    if (result == DDS::RETCODE_OK) {
        uWriterQos = u_writerQosNew (NULL);
        if (uWriterQos == NULL) {
            result = DDS::RETCODE_OUT_OF_RESOURCES;
            CPP_REPORT(result, "Could not copy DataWriterQos.");
        }
    }

    if (result == DDS::RETCODE_OK) {
        result = this->write_lock();
        if (result == DDS::RETCODE_OK) {
            if (&qos == &DATAWRITER_QOS_DEFAULT) {
                /* QoS consistency is checked by set_default_datawriter_qos */
                result = publisher->get_default_datawriter_qos (writerQos);
                if (result == DDS::RETCODE_OK) {
                    result = DDS::OpenSplice::Utils::copyQosIn (
                        writerQos, uWriterQos);
                }
            } else if (&qos == &DATAWRITER_QOS_USE_TOPIC_QOS) {
                result = publisher->get_default_datawriter_qos (writerQos);
                if (result == DDS::RETCODE_OK) {
                    result = topic->get_qos(topicQos);
                    if (result == DDS::RETCODE_OK) {
                        result = publisher->copy_from_topic_qos (
                            writerQos, topicQos);
                        if (result == DDS::RETCODE_OK) {
                            result = DDS::OpenSplice::Utils::qosIsConsistent (
                                writerQos);
                            if (result == DDS::RETCODE_OK) {
                                result = DDS::OpenSplice::Utils::copyQosIn (
                                    writerQos, uWriterQos);
                            }
                        }
                    }
                }
            } else {
                result = DDS::OpenSplice::Utils::copyQosIn (
                    qos, uWriterQos);
            }

            if (result == DDS::RETCODE_OK) {
                uWriter = u_writer (this->rlReq_get_user_entity ());
                assert (uWriter != NULL);
                uResult = u_writerSetQos (uWriter, uWriterQos);
                result = uResultToReturnCode (uResult);
                if (result != DDS::RETCODE_OK) {
                    CPP_REPORT(result, "Could not apply DataWriterQos.");
                }
            }

            this->unlock();
        }
    }

    if (uWriterQos != NULL) {
        u_writerQosFree (uWriterQos);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_qos (
    DDS::DataWriterQos &qos
) THROW_ORB_EXCEPTIONS
{
   DDS::ReturnCode_t result;
   u_writer uWriter;
   u_writerQos uWriterQos;
   u_result uResult;

   CPP_REPORT_STACK();

   if (&qos == &DATAWRITER_QOS_DEFAULT) {
       result = DDS::RETCODE_BAD_PARAMETER;
       CPP_REPORT(result, "QoS 'DATAWRITER_QOS_DEFAULT' is read-only.");
   } else if (&qos == &DATAWRITER_QOS_USE_TOPIC_QOS) {
       result = DDS::RETCODE_BAD_PARAMETER;
       CPP_REPORT(result, "QoS 'DATAWRITER_QOS_USE_TOPIC_QOS' is read-only.");
   } else {
       result = this->check ();
   }

   if (result == DDS::RETCODE_OK) {
       uWriter = u_writer (this->rlReq_get_user_entity ());
       uResult = u_writerGetQos(uWriter, &uWriterQos);
       result = uResultToReturnCode (uResult);
       if (result == DDS::RETCODE_OK) {
           result = DDS::OpenSplice::Utils::copyQosOut (
               uWriterQos, qos);
           u_writerQosFree(uWriterQos);
       } else {
           CPP_REPORT(result, "Could not copy DataWriterQos.");
       }
   }

   CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

   return result;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::set_listener (
    DDS::DataWriterListener_ptr a_listener,
    DDS::StatusMask mask
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;

    CPP_REPORT_STACK();
    result = DDS::OpenSplice::Entity::nlReq_set_listener(a_listener, mask);
    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

DDS::DataWriterListener_ptr
DDS::OpenSplice::DataWriter::get_listener (
) THROW_ORB_EXCEPTIONS
{
    DDS::DataWriterListener_ptr listener;

    CPP_REPORT_STACK();
    listener = dynamic_cast<DDS::DataWriterListener_ptr>(
        DDS::OpenSplice::Entity::nlReq_get_listener());
    CPP_REPORT_FLUSH(this, listener == NULL);

    return listener;
}

DDS::Topic_ptr
DDS::OpenSplice::DataWriter::get_topic (
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    DDS::Topic_ptr topic_ptr = NULL;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        topic_ptr = DDS::Topic::_duplicate(this->topic);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return topic_ptr;
}

DDS::Publisher_ptr
DDS::OpenSplice::DataWriter::get_publisher (
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    DDS::Publisher_ptr publisher_ptr = NULL;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        publisher_ptr = DDS::Publisher::_duplicate(this->publisher);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return publisher_ptr;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::wait_for_acknowledgments (
    const DDS::Duration_t &max_wait
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    os_duration timeout;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        result = DDS::OpenSplice::Utils::copyDurationIn(max_wait, timeout);
        if (result == DDS::RETCODE_OK) {
            uWriter = u_writer (this->rlReq_get_user_entity());
            assert (uWriter != NULL);
            uResult = u_writerWaitForAcknowledgments(
                    uWriter, timeout);
            result = uResultToReturnCode(uResult);
        }
    }

    CPP_REPORT_FLUSH(this, (result != DDS::RETCODE_OK) && (result != DDS::RETCODE_TIMEOUT));

    return result;
}

u_result
DDS::OpenSplice::DataWriter::copy_liveliness_lost_status(
    u_status info,
    void *arg)
{
    struct v_livelinessLostInfo *from = reinterpret_cast<struct v_livelinessLostInfo *>(info);
    DDS::LivelinessLostStatus *to = reinterpret_cast<DDS::LivelinessLostStatus *>(arg);

    copyStatusOut(*from, *to);

    return U_RESULT_OK;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_liveliness_lost_status (
    DDS::LivelinessLostStatus &status
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetLivelinessLostStatus(
                uWriter, TRUE, copy_liveliness_lost_status, &status);
        result = uResultToReturnCode (uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

u_result
DDS::OpenSplice::DataWriter::copy_deadline_missed_status(
    u_status info,
    void *arg)
{
    struct v_deadlineMissedInfo *from = reinterpret_cast<struct v_deadlineMissedInfo *>(info);
    DDS::OfferedDeadlineMissedStatus *to = reinterpret_cast<DDS::OfferedDeadlineMissedStatus *>(arg);
    u_result uResult = U_RESULT_INTERNAL_ERROR;
    v_object instance;

    to->total_count = from->totalCount;
    to->total_count_change = from->totalChanged;

    if (!v_handleIsNil(from->instanceHandle)) {
        if (v_handleClaim(from->instanceHandle, &instance) == V_HANDLE_OK) {
            to->last_instance_handle = u_instanceHandleNew(v_public(instance));
            if (v_handleRelease(from->instanceHandle) == V_HANDLE_OK) {
                uResult = U_RESULT_OK;
            }
        }
    } else {
        uResult = U_RESULT_OK;
    }

    return uResult;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_offered_deadline_missed_status (
    DDS::OfferedDeadlineMissedStatus &status
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check ();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetDeadlineMissedStatus(
                uWriter, TRUE, copy_deadline_missed_status, &status);
        result = uResultToReturnCode (uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

u_result
DDS::OpenSplice::DataWriter::copy_incompatible_qos_status(
    u_status info,
    void *arg)
{
    DDS::ReturnCode_t result;
    struct v_incompatibleQosInfo *from = reinterpret_cast<struct v_incompatibleQosInfo *>(info);
    DDS::OfferedIncompatibleQosStatus *to = reinterpret_cast<DDS::OfferedIncompatibleQosStatus *>(arg);

    result = copyStatusOut(*from, *to);

    return ReturnCodeTouResult(result);
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_offered_incompatible_qos_status (
    DDS::OfferedIncompatibleQosStatus &status
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check ();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetIncompatibleQosStatus(
                uWriter, TRUE, copy_incompatible_qos_status, &status);
        result = uResultToReturnCode (uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

u_result
DDS::OpenSplice::DataWriter::copy_publication_matched_status(
    u_status info,
    void *arg)
{
    struct v_topicMatchInfo *from = reinterpret_cast<struct v_topicMatchInfo *>(info);
    DDS::PublicationMatchedStatus *to = reinterpret_cast<DDS::PublicationMatchedStatus *>(arg);

    copyStatusOut(*from, *to);

    return U_RESULT_OK;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_publication_matched_status (
    DDS::PublicationMatchedStatus &status
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetPublicationMatchStatus(
                uWriter, TRUE, copy_publication_matched_status, &status);
        result = uResultToReturnCode(uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::assert_liveliness (
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerAssertLiveliness(
                uWriter);
        result = uResultToReturnCode(uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

v_result
DDS::OpenSplice::DataWriter::copy_matched_subscription(
    u_subscriptionInfo *info,
    void *arg)
{
    DDS::InstanceHandleSeq *seq  = reinterpret_cast<DDS::InstanceHandleSeq *>(arg);
    DDS::InstanceHandle_t handle = u_instanceHandleFromGID(info->key);

    DDS::OpenSplice::Utils::appendSequenceItem<
                                        DDS::InstanceHandleSeq,
                                        DDS::InstanceHandle_t>(
                                                        *seq,
                                                        handle);

    return V_RESULT_OK;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_matched_subscriptions (
    DDS::InstanceHandleSeq &subscription_handles
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetMatchedSubscriptions(
                uWriter, copy_matched_subscription, &subscription_handles);
        result = uResultToReturnCode(uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

v_result
DDS::OpenSplice::DataWriter::copy_matched_subscription_data(
    u_subscriptionInfo *info,
    void *arg)
{
    DDS::SubscriptionBuiltinTopicData *to = reinterpret_cast<DDS::SubscriptionBuiltinTopicData *>(arg);
    __DDS_SubscriptionBuiltinTopicData__copyOut(info, to);
    return V_RESULT_OK;
}

DDS::ReturnCode_t
DDS::OpenSplice::DataWriter::get_matched_subscription_data (
    DDS::SubscriptionBuiltinTopicData &subscription_data,
    DDS::InstanceHandle_t subscription_handle
) THROW_ORB_EXCEPTIONS
{
    DDS::ReturnCode_t result;
    u_writer uWriter;
    u_result uResult;

    CPP_REPORT_STACK();

    result = this->check();
    if (result == DDS::RETCODE_OK) {
        uWriter = u_writer(this->rlReq_get_user_entity());
        assert (uWriter != NULL);
        uResult = u_writerGetMatchedSubscriptionData(
                uWriter, (u_instanceHandle)subscription_handle, copy_matched_subscription_data, &subscription_data);
        result = uResultToReturnCode(uResult);
    }

    CPP_REPORT_FLUSH(this, result != DDS::RETCODE_OK);

    return result;
}

void
DDS::OpenSplice::DataWriter::nlReq_notify_listener(
    DDS::OpenSplice::Entity *sourceEntity,
    DDS::ULong               triggerMask,
    void                    *eventData)
{
    DDS::DataWriterListener_ptr listener;

    /* Using _narrow to cast Listener, this increases the refcount to ensure
     * the ListenerObject is not deleted while notifying. */
    listener = DDS::DataWriterListener::_narrow(this->listener);
    if (listener) {

        if (triggerMask & V_EVENT_LIVELINESS_LOST) {
            DDS::LivelinessLostStatus status;
            DDS::OpenSplice::Utils::copyStatusOut(v_writerStatus(eventData)->livelinessLost,
                                                  status);
            listener->on_liveliness_lost(dynamic_cast<DDS::DataWriter_ptr>(sourceEntity),
                                         status);
        }

        if (triggerMask & V_EVENT_OFFERED_DEADLINE_MISSED) {
            DDS::OfferedDeadlineMissedStatus status;
            DDS::OpenSplice::Utils::copyStatusOut(v_writerStatus(eventData)->deadlineMissed,
                                                  status);
            listener->on_offered_deadline_missed(dynamic_cast<DDS::DataWriter_ptr>(sourceEntity),
                                                 status);
        }

        if (triggerMask & V_EVENT_OFFERED_INCOMPATIBLE_QOS) {
            DDS::OfferedIncompatibleQosStatus status;
            DDS::OpenSplice::Utils::copyStatusOut(v_writerStatus(eventData)->incompatibleQos,
                                                  status);
            listener->on_offered_incompatible_qos(dynamic_cast<DDS::DataWriter_ptr>(sourceEntity),
                                                  status);
        }

        if (triggerMask & V_EVENT_PUBLICATION_MATCHED) {
            DDS::PublicationMatchedStatus status;
            DDS::OpenSplice::Utils::copyStatusOut(v_writerStatus(eventData)->publicationMatch,
                                                  status);
            listener->on_publication_matched(dynamic_cast<DDS::DataWriter_ptr>(sourceEntity),
                                             status);
        }
        DDS::release(listener);
    }
}


text:
/*
    Nombre del programa: Program_4
    Nombre: Andrés David Mojica Ospina
    Fecha: 14-03-2016
    Descripción: Clase que permite probar los metodos del programa 4
*/
package test;

import controller.Estadistica;
import controller.Reporte;
import java.text.DecimalFormat;
import java.util.LinkedList;
import model.AbrirDatos;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import static org.junit.Assert.*;

public class TestProgram
{
    private final Estadistica estadistica = new Estadistica();
    private final AbrirDatos abrir_datos = new AbrirDatos();
    private final Reporte reporte = new Reporte();

    LinkedList loc_method;
    LinkedList pgs_chapter;
    LinkedList loc_method_logaritmo;
    LinkedList loc_menos_promedio;
    LinkedList rangos_logaritmicos;
    LinkedList rangos;
    Double promedio;
    Double varianza;
    Double desviacion_estandar;

    @Before
    public void setUp()
    {

        loc_method = abrir_datos.llenarLista("src/main/java/data/loc-method.txt");

        loc_method_logaritmo = estadistica.logaritmoNeperiano(loc_method);
        promedio = estadistica.obtenerPromedio(loc_method_logaritmo);
        loc_menos_promedio = estadistica.obtenerLogartimoMenosPromedio(loc_method_logaritmo, promedio);
        varianza = estadistica.obtenerVarianza(loc_menos_promedio);
        desviacion_estandar = estadistica.obtenerDesviacionEstandar(varianza);
        rangos_logaritmicos = estadistica.obtenerRangosLogaritmicos(promedio, desviacion_estandar);
        rangos = estadistica.obtenerAntilogaritmo(rangos_logaritmicos);

        // Clase reporte
    }

    // Test de la clase AbrirDatos
    @Test
    public void testAbrirDatos()
    {
        assertNotNull(loc_method);
    }

    // Test de la clase Estadistica
    @Test
    public void testLogaritmoNeperiano()
    {
        assertEquals(1.7918, Math.round((double) loc_method_logaritmo.get(0)*10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerPromedio()
    {
        assertEquals(2.8015, Math.round(promedio * 10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerLogartimoMenosPromedio()
    {
        assertEquals(1.0196, Math.round((double) loc_menos_promedio.get(0)*10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerVarianza()
    {
        assertEquals(0.4363, Math.round(varianza * 10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerDesviacionEstandar()
    {
        assertEquals(0.6605, Math.round(desviacion_estandar * 10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerRangosLogaritmicos()
    {
        assertEquals(1.4805, Math.round((double) rangos_logaritmicos.get(0)*10000.0)/10000.0, 0);
    }

    @Test
    public void testObtenerAntilogaritmo()
    {
        assertEquals(4.3953, Math.round((double) rangos.get(0)*10000.0)/10000.0, 0);
    }

}


text:
<?php
/**
 * The template for displaying 404 pages (Not Found).
 */
?>

<!DOCTYPE html>
<html <?php language_attributes(); ?> style="margin-top: 0 !important;">

<meta charset="<?php bloginfo( 'charset' ); ?>" />
<meta content="width=device-width, initial-scale=1.0, user-scalable=no" name="viewport">
<title><?php wp_title( '|', true, 'right' ); ?></title>
<link rel="profile" href="http://gmpg.org/xfn/11" />
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />

<?php wp_head(); ?>

<body <?php body_class(); ?>>

<a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?>

<?php dynamic_sidebar('dw_focus_header'); ?>

	            <?php
	            	wp_nav_menu(array(
	            	'theme_location'  => 'primary',
	            	'container'       => '',
	            	'menu_class'      => 'nav',
	            	'depth'           => 1) );
	            ?>

				<?php dynamic_sidebar('dw_focus_under_navigation'); ?>

<?php _e('404!','dw_focus') ?>

<?php _e( 'The page you were looking for is not here', 'dw_focus' ); ?>

					<?php get_search_form(); ?>

	            <?php _e('Maybe you are interested in:','dw_focus') ?>
	            <?php
	            	wp_nav_menu(array(
	            	'theme_location'  => 'primary',
	            	'container'       => '',
	            	'menu_class'      => 'nav',
	            	'depth'           => 1) );
	            ?>


text:
namespace content {
class Shell;
}

@interface ShellToolbarDelegate : NSObject<NSToolbarDelegate> {
 @private
  content::Shell* shell_;
  NSTextField* entry_;
  NSToolbarItem* back_button_;
  NSToolbarItem* forward_button_;
  NSToolbarItem* refresh_stop_button_;
  NSToolbarItem* devtools_button_;
  NSToolbarItem* refresh_dev_button_;
}

- (id)initWithShell:(content::Shell*)shell;
- (void)buttonPressed:(id)sender;
- (void)urlEntered:(id)sender;
- (void)setEnabled:(BOOL)enabled
         forButton:(nw::NativeWindow::TOOLBAR_BUTTON)button;
- (void)setUrl:(NSString*)url;
- (void)setIsLoading:(BOOL)loading;

- (NSToolbarItem *)toolbar:(NSToolbar *)toolbar
     itemForItemIdentifier:(NSString *)itemIdentifier
 willBeInsertedIntoToolbar:(BOOL)flag;
- (NSArray *)toolbarAllowedItemIdentifiers:(NSToolbar *)toolbar;
- (NSArray *)toolbarDefaultItemIdentifiers:(NSToolbar *)toolbar;
@end

#endif  // CONTENT_NW_SRC_BROWSER_SHELL_TOOLBAR_DELEGATE_MAC_H_


text:
#include <sys/compiler.h>
#include <sys/cpu.h>
#include <sys/types.h>
#include <sys/mman.h>
#include <mem/alloc.h>

#include <errno.h>
#include <string.h>

void *
vm_page_reserve(void)
{
	void *page = NULL;
	return page;
}

void *
vm_page_alloc(u64 size)
{
	void *page = malloc(align_page(size));
	return page;
}

void
vm_page_free(void *page, u64 size)
{
	free(page);
}

void *
vm_page_inquire(void *addr)
{
	return NULL;
}

void *
vm_page_extend(void *page, u64 olen, u64 size)
{
	/* TODO: mremap() on base addr when MM_CONT_ALLOC is used */
	void *addr = vm_page_alloc(size);
	memcpy(addr, page, min(olen, size));
	vm_page_free(page, olen);
	return addr;
}


text:
from openprocurement.api.utils import opresource
from openprocurement.api.models import get_now
from openprocurement.tender.openua.views.tender_document import TenderUaDocumentResource
from openprocurement.tender.openua.utils import calculate_business_date
from openprocurement.tender.twostage.models import TENDERING_EXTRA_PERIOD

@opresource(name='Tender Two Stage Documents',
            collection_path='/tenders/{tender_id}/documents',
            path='/tenders/{tender_id}/documents/{document_id}',
            procurementMethodType='aboveThresholdTS',
            description="Tender Two Stage related binary files (PDFs, etc.)")
class TenderTSDocumentResource(TenderUaDocumentResource):

    def validate_update_tender(self, operation):
        if self.request.authenticated_role != 'auction' and self.request.validated['tender_status'] != 'active.tendering' or \
           self.request.authenticated_role == 'auction' and self.request.validated['tender_status'] not in ['active.auction', 'active.qualification']:
            self.request.errors.add('body', 'data', 'Can\'t {} document in current ({}) tender status'.format(operation, self.request.validated['tender_status']))
            self.request.errors.status = 403
            return
        if self.request.validated['tender_status'] == 'active.tendering' and calculate_business_date(get_now(), TENDERING_EXTRA_PERIOD, self.request.validated['tender']) > self.request.validated['tender'].tenderPeriod.endDate:
            self.request.errors.add('body', 'data', 'tenderPeriod should be extended by {0.days} days'.format(TENDERING_EXTRA_PERIOD))
            self.request.errors.status = 403
            return
        return True


text:
The example below creates a Kubernetes cluster with 4 worker node Virtual Machines and a master Virtual Machine (i.e. 5 VMs in your cluster). This cluster is set up and controlled from your workstation (or wherever you find convenient).

### Getting VMs

1. You need a Google Cloud Platform account with billing enabled. Visit
   [http://cloud.google.com/console](http://cloud.google.com/console) for more details.
2. Make sure you can start up a GCE VM.  At least make sure you can do the [Create an instance](https://developers.google.com/compute/docs/quickstart#addvm) part of the GCE Quickstart.
3. Make sure you can ssh into the VM without interactive prompts. You'll need to set up a ssh key and expose port 22 in the firewall if you choose to use a network other than the default network (`gcutil addfirewall --description "SSH allowed from anywhere" --allowed=tcp:22 default-ssh`)
4. You need to have the Google Cloud Storage API, and the Google Cloud Storage JSON API enabled.

### Prerequisites for your workstation

1. You must have Go (version 1.2 or later) installed: [www.golang.org](http://www.golang.org).
2. You must have the [`gcloud` components](https://developers.google.com/cloud/sdk/) installed.
3. Ensure that your `gcloud` components are up-to-date by running `gcloud components update`.
4. Install godep (optional, only required when modifying package dependencies). [Instructions here](https://github.com/GoogleCloudPlatform/kubernetes#installing-godep)
5. Get the Kubernetes source:
      * Kubernetes 0.3 \[[.tar.gz](https://github.com/GoogleCloudPlatform/kubernetes/archive/v0.3.tar.gz)\] \[[.zip](https://github.com/GoogleCloudPlatform/kubernetes/archive/v0.3.zip)\]

### Setup

The setup script builds Kubernetes, then creates Google Compute Engine instances, firewall rules, and routes:

```
cd kubernetes
hack/dev-build-and-up.sh
```

The script above relies on Google Storage to deploy the software to instances running in GCE. It uses the Google Storage APIs so the "Google Cloud Storage JSON API" setting must be enabled for the project in the Google Developers Console (https://cloud.google.com/console#/project).

The instances must also be able to connect to each other using their private IP. The script uses the "default" network which should have a firewall rule called "default-allow-internal" which allows traffic on any port on the private IPs.
If this rule is missing from the default network or if you change the network being used in `cluster/config-default.sh` create a new rule with the following field values:
* Source Ranges: 10.0.0.0/8
* Allowed Protocols or Port: tcp:1-65535;udp:1-65535;icmp

### Running a container (simple version)

Once you have your instances up and running, the `build-go.sh` script sets up
your Go workspace and builds the Go components.

The `kubecfg.sh` script spins up two containers, running [Nginx](http://nginx.org/en/) and with port 80 mapped to 8080:

```
cd kubernetes
hack/build-go.sh
cluster/kubecfg.sh -p 8080:80 run dockerfile/nginx 2 myNginx
```

To stop the containers:
```
cluster/kubecfg.sh stop myNginx
```

To delete the containers:
```
cluster/kubecfg.sh rm myNginx
```

### Running a container (more complete version)

Assuming you've run `hack/dev-build-and-up.sh` and `hack/build-go.sh`, you
can create a pod like this:

```
cd kubernetes
cluster/kubecfg.sh -c api/examples/pod.json create /pods
```

Where pod.json contains something like:

```
{
  "id": "php",
  "kind": "Pod",
  "apiVersion": "v1beta1",
  "desiredState": {
    "manifest": {
      "version": "v1beta1",
      "id": "php",
      "containers": [{
        "name": "nginx",
        "image": "dockerfile/nginx",
        "ports": [{
          "containerPort": 80,
          "hostPort": 8080
        }],
        "livenessProbe": {
          "enabled": true,
          "type": "http",
          "initialDelaySeconds": 30,
          "httpGet": {
            "path": "/index.html",
            "port": "8080"
          }
        }
      }]
    }
  },
  "labels": {
    "name": "foo"
  }
}
```

You can see your cluster's pods:

```
cluster/kubecfg.sh list pods
```

and delete the pod you just created:

```
cluster/kubecfg.sh delete pods/php
```

Look in `api/examples/` for more examples

### Tearing down the cluster
```
cd kubernetes
cluster/kube-down.sh
```


text:
<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>AngularClient</title>
  <base href="/">

  <meta name="viewport" content="width=device-width, initial-scale=1">

  <!-- Materials Icons -->
  <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">

  <link rel="icon" type="image/x-icon" href="favicon.ico">
</head>
<body>
  <script>
    window.fbAsyncInit = function() {
      FB.init({
        appId            : '1723596491048606',
        autoLogAppEvents : true,
        xfbml            : true,
        version          : 'v2.10'
      });
      FB.AppEvents.logPageView();
    };

    (function(d, s, id){
      var js, fjs = d.getElementsByTagName(s)[0];
      if (d.getElementById(id)) {return;}
      js = d.createElement(s); js.id = id;
      js.src = "https://connect.facebook.net/en_US/sdk.js";
      fjs.parentNode.insertBefore(js, fjs);
    }(document, 'script', 'facebook-jssdk'));
  </script>
  <app-root></app-root>
</body>
</html>


text:
<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-width">
        <title>Apartment Checklist</title>

        <!-- compiled css output -->
        <link href="css/ionic.app.css" rel="stylesheet">

        <!-- ionic/angularjs js -->
        <script src="lib/ionic/js/ionic.bundle.js"></script>

        <!-- cordova script (this will be a 404 during development) -->
        <script src="cordova.js"></script>

        <!-- your app's js -->
        <script src="js/app.js"></script>
        <script src="js/controllers.js"></script>
        <script src="js/services.js"></script>
        <script src="js/ngStorage.min.js"></script>
    </head>
    <body ng-app="apartmentChecklist" class="platform-android platform-cordova platform-webview">
        <ion-nav-view></ion-nav-view>
    </body>
</html>


text:
(function () {
    // Aggiunge il polyfill bind()
    var scriptElem = document.createElement('script');
    scriptElem.setAttribute('src', 'scripts/android2.3-jscompat.js');
    if (document.body) {
        document.body.appendChild(scriptElem);
    } else {
        document.head.appendChild(scriptElem);
    }
}());


text:
using LinqToDB.Mapping;

#pragma warning disable 1573, 1591
#nullable enable

namespace Cli.Default.Sybase
{
	[Table("Child")]
	public class Child
	{
		[Column("ParentID")] public int? ParentId { get; set; } // int
		[Column("ChildID" )] public int? ChildId  { get; set; } // int
	}
}


text:
package org.jbpm.workbench.ht.client;

import javax.annotation.PostConstruct;

import org.jboss.errai.ioc.client.api.EntryPoint;
import org.jbpm.workbench.ht.client.resources.HumanTaskResources;

@EntryPoint
public class HumanTaskEntryPoint {

    @PostConstruct
    public void init() {
        HumanTaskResources.INSTANCE.css().ensureInjected();
    }
}


text:
function [Ybus, Yf, Yt, Yff,Ytt,Yft,Ytf] = getYMatrix(baseMVA, bus, branch)
%MAKEYBUS   Builds the bus admittance matrix and branch admittance matrices.
%   [YBUS, YF, YT] = MAKEYBUS(MPC)
%   [YBUS, YF, YT] = MAKEYBUS(BASEMVA, BUS, BRANCH)
%
%   Returns the full bus admittance matrix (i.e. for all buses) and the
%   matrices YF and YT which, when multiplied by a complex voltage vector,
%   yield the vector currents injected into each line from the "from" and
%   "to" buses respectively of each line. Does appropriate conversions to p.u.
%   Inputs can be a MATPOWER case struct or individual BASEMVA, BUS and
%   BRANCH values. Bus numbers must be consecutive beginning at 1 (internal
%   ordering).
%
%   See also MAKEJAC, MAKESBUS, EXT2INT.

%   MATPOWER
%   Copyright (c) 1996-2015 by Power System Engineering Research Center (PSERC)
%   by Ray Zimmerman, PSERC Cornell
%
%   $Id: makeYbus.m 2644 2015-03-11 19:34:22Z ray $
%
%   This file is part of MATPOWER.
%   Covered by the 3-clause BSD License (see LICENSE file for details).
%   See http://www.pserc.cornell.edu/matpower/ for more info.

if nargin < 3
    mpc     = baseMVA;
    baseMVA = mpc.baseMVA;
    bus     = mpc.bus;
    branch  = mpc.branch;
end

%% constants
if ~isempty(bus)
    nb = size(bus, 1);          %% number of buses
end
nl = size(branch, 1);       %% number of lines

%% define named indices into bus, branch matrices
[PQ, PV, REF, NONE, BUS_I, BUS_TYPE, PD, QD, GS, BS, BUS_AREA, VM, ...
    VA, BASE_KV, ZONE, VMAX, VMIN, LAM_P, LAM_Q, MU_VMAX, MU_VMIN] = idx_bus;
[F_BUS, T_BUS, BR_R, BR_X, BR_B, RATE_A, RATE_B, RATE_C, ...
    TAP, SHIFT, BR_STATUS, PF, QF, PT, QT, MU_SF, MU_ST, ...
    ANGMIN, ANGMAX, MU_ANGMIN, MU_ANGMAX] = idx_brch;

%% check that bus numbers are equal to indices to bus (one set of bus numbers)
if ~isempty(bus)
    if any(bus(:, BUS_I) ~= (1:nb)')
        error('buses must appear in order by bus number')
    end
end

%% for each branch, compute the elements of the branch admittance matrix where
%%
%%      | If |   | Yff  Yft |   | Vf |
%%      |    | = |          | * |    |
%%      | It |   | Ytf  Ytt |   | Vt |
%%
stat = branch(:, BR_STATUS);                    %% ones at in-service branches
Ys = stat ./ (branch(:, BR_R) + 1j * branch(:, BR_X));  %% series admittance
Bc = stat .* branch(:, BR_B);                           %% line charging susceptance
tap = ones(nl, 1);                              %% default tap ratio = 1
i = find(branch(:, TAP));                       %% indices of non-zero tap ratios
tap(i) = branch(i, TAP);                        %% assign non-zero tap ratios
tap = tap .* exp(1j*pi/180 * branch(:, SHIFT)); %% add phase shifters
Ytt = Ys + 1j*Bc/2;
Yff = Ytt ./ (tap .* conj(tap));
Yft = - Ys ./ conj(tap);
Ytf = - Ys ./ tap;

%% we only need Yff and Ytt
if isempty(bus)
    Ybus=[];
    Yf=[];
    Yt=[];
    return;
end

%% compute shunt admittance
%% if Psh is the real power consumed by the shunt at V = 1.0 p.u.
%% and Qsh is the reactive power injected by the shunt at V = 1.0 p.u.
%% then Psh - j Qsh = V * conj(Ysh * V) = conj(Ysh) = Gs - j Bs,
%% i.e. Ysh = Psh + j Qsh, so ...
Ysh = (bus(:, GS) + 1j * bus(:, BS)) / baseMVA; %% vector of shunt admittances

%% build connection matrices
f = branch(:, F_BUS);                           %% list of "from" buses
t = branch(:, T_BUS);                           %% list of "to" buses
Cf = sparse(1:nl, f, ones(nl, 1), nl, nb);      %% connection matrix for line & from buses
Ct = sparse(1:nl, t, ones(nl, 1), nl, nb);      %% connection matrix for line & to buses

%% build Yf and Yt such that Yf * V is the vector of complex branch currents injected
%% at each branch's "from" bus, and Yt is the same for the "to" bus end
i = [1:nl; 1:nl]';                              %% double set of row indices
Yf = sparse(i, [f; t], [Yff; Yft], nl, nb);
Yt = sparse(i, [f; t], [Ytf; Ytt], nl, nb);
% Yf = spdiags(Yff, 0, nl, nl) * Cf + spdiags(Yft, 0, nl, nl) * Ct;
% Yt = spdiags(Ytf, 0, nl, nl) * Cf + spdiags(Ytt, 0, nl, nl) * Ct;

%% build Ybus
Ybus = Cf' * Yf + Ct' * Yt + ...                %% branch admittances
    sparse(1:nb, 1:nb, Ysh, nb, nb);        %% shunt admittance


text:
NSString * const CMIncludeDistanceKey = @"distance";
NSString * const CMDistanceUnitsKey = @"units";

NSString * const CMDistanceUnitsKm = @"km";
NSString * const CMDistanceUnitsMi = @"mi";
NSString * const CMDistanceUnitsM = @"m";
NSString * const CMDistanceUnitsFt = @"ft";

@implementation CMDistance

@synthesize distance;
@synthesize units;

- initWithDistance:(double)theDistance andUnits:(NSString *)theUnits {
    if(self = [super init]) {
        distance = theDistance;
        units = theUnits;
    }

    return self;
}

@end


text:
@interface MJCSoecialDemoVC15 ()<MJCSegmentDelegate>
@property (nonatomic,weak) MJCSegmentInterface *interFace;
@end

@implementation MJCSoecialDemoVC15

- (void)viewDidLoad {
    [super viewDidLoad];

    MJCTestViewController *vc1 = [[MJCTestViewController alloc]init];
    MJCTestTableViewController *vc2 = [[MJCTestTableViewController alloc]init];
    MJCTestViewController1 *vc3 = [[MJCTestViewController1 alloc]init];
    MJCTestCollectVC *vc4 = [[MJCTestCollectVC alloc]init];
    MJCTestViewController *vc5 = [[MJCTestViewController alloc]init];
    MJCTestViewController *vc6 = [[MJCTestViewController alloc]init];
    MJCTestViewController *vc7 = [[MJCTestViewController alloc]init];
    MJCTestViewController *vc8 = [[MJCTestViewController alloc]init];
    NSArray *vcarrr = @[vc1,vc2,vc3,vc4,vc5,vc6,vc7,vc8];
    NSArray *titlesArr = @[@"荣耀",@"联盟",@"DNF",@"CF",@"飞车",@"炫舞",@"天涯",@"诛仙世界"];
    NSArray *imageArr =@[@"bulb-2",@"cloud-2",@"diamond-2",@"food-2",@"heart-2"];
    NSArray *imageArr1 = @[@"bulb",@"cloud",@"diamond",@"food",@"heart"];
    NSArray *backimageArr =@[@"111",@"222",@"1111",@"234",@"567",@"666",@"888"];
    NSArray *backimageArr1 = @[@"123",@"333",@"345",@"456",@"777",@"999",@"555"];
    for (int i = 0 ; i < vcarrr.count; i++) {//赋值标题
        UIViewController *vc = vcarrr[i];
        vc.title = titlesArr[i];
    }

    NSArray *colorArr = @[[UIColor redColor],[UIColor blackColor],[UIColor purpleColor],[UIColor lightGrayColor],[UIColor orangeColor]];
    NSArray *colorArr1 = @[[UIColor blackColor],[UIColor redColor],[UIColor lightGrayColor],[UIColor purpleColor],[UIColor yellowColor]];

    MJCSegmentInterface *interFace =  [MJCSegmentInterface jc_initWithFrame:CGRectMake(0,64,self.view.jc_width, self.view.jc_height-64) interFaceStyleToolsBlock:^(MJCSegmentStylesTools *jc_tools) {
        jc_tools.
        jc_titlesViewFrame(CGRectMake(0, 0, self.view.jc_width, 100)).
        jc_titleBarStyles(MJCTitlesScrollStyle).
        jc_indicatorStyles(MJCIndicatorEqualItemEffect).
        jc_itemTextImageStyle(MJCLeftRightEffect).
        jc_itemSelectedSegmentIndex(4).
        jc_defaultItemShowCount(3).
        jc_itemTextFontSize(13).
        jc_titlesViewBackColor([UIColor orangeColor]).
        jc_itemTextNormalColor([UIColor redColor]).
        jc_itemTextSelectedColor([UIColor purpleColor]).
        jc_titlesViewBackImage([UIImage imageNamed:@"back"]).
        jc_itemBackImageNormal([UIImage imageNamed:@"222"]).
        jc_itemBackImageSelected([UIImage imageNamed:@"456"]).
        jc_itemBackImageArraySelected(backimageArr).
        jc_itemBackImageArrayNormal(backimageArr1).
        jc_itemImageSelected([UIImage imageNamed:@"food-2"]).
        jc_itemImageNormal([UIImage imageNamed:@"food"]).
        jc_itemImageArrayNormal(imageArr).
        jc_itemImageArraySelected(imageArr1).
        jc_indicatorColor([UIColor redColor]).
        jc_indicatorImage([UIImage imageNamed:@"箭头"]).
        jc_loadAllChildViewEnabled(YES).
        jc_indicatorHidden(NO).
        jc_childScollEnabled(YES).
        jc_childScollAnimalEnabled(YES).
        jc_indicatorFollowEnabled(YES).
        jc_tabItemSizeToFitIsEnabled(YES, NO, NO).
        jc_itemEdgeinsets(MJCItemEdgeInsetsMake(0, 10, 0, 10, 10)).
        jc_itemImagesEdgeInsets(UIEdgeInsetsMake(10,10,10,0)).
        jc_itemTextsEdgeInsets(UIEdgeInsetsMake(10,10,10,10)).
        jc_itemTextGradientEnabled(YES).
        jc_itemTextHidden(NO).
        jc_titlesViewPenetrationEnabled(NO).
        jc_indicatorColorEqualTextColorEnabled(YES).
        jc_childsContainerBackColor([UIColor redColor]).
        jc_itemImageSize(CGSizeMake(15, 15)).
        jc_indicatorFrame(CGRectMake(0,jc_tools.titlesViewFrame.size.height - 10,30,10)).
        jc_itemTextZoomEnabled(YES, 14).
        jc_itemTextColorArrayNormal(colorArr).jc_itemTextColorArraySelected(colorArr1).
        jc_indicatorsAnimalsEnabled(YES).
        jc_scaleLayoutEnabled(NO).
        jc_itemBackColorNormal([UIColor redColor]);
    }];
    interFace.delegate = self;
    [self.view addSubview:interFace];
    [interFace intoTitlesArray:titlesArr intoChildControllerArray:vcarrr hostController:self];
    _interFace = interFace;
}
-(void)mjc_tabitemDataWithTabitemArray:(NSArray<UIButton *> *)tabItemArray childsVCAarray:(NSArray<UIViewController *> *)childsVCAarray segmentInterface:(MJCSegmentInterface *)segmentInterface
{
    NSLog(@"%@",tabItemArray);
    NSLog(@"%@",childsVCAarray);
    NSLog(@"%@",segmentInterface);
}

-(void)mjc_ClickEventWithItem:(UIButton *)tabItem childsController:(UIViewController *)childsController segmentInterface:(MJCSegmentInterface *)segmentInterface
{
    NSLog(@"%ld",tabItem.tag);
    NSLog(@"%@",childsController);
    NSLog(@"%@",segmentInterface);
}
-(void)mjc_scrollDidEndDeceleratingWithItem:(UIButton *)tabItem childsController:(UIViewController *)childsController indexPage:(NSInteger)indexPage segmentInterface:(MJCSegmentInterface *)segmentInterface
{
    NSLog(@"%ld",tabItem.tag);
    NSLog(@"%ld",indexPage);
    NSLog(@"%@",childsController);
    NSLog(@"%@",segmentInterface);
}
-(void)mjc_cancelClickEventWithItem:(UIButton *)tabItem childsController:(UIViewController *)childsController segmentInterface:(MJCSegmentInterface *)segmentInterface
{
    NSLog(@"%ld",tabItem.tag);
    NSLog(@"%@",childsController);
    NSLog(@"%@",segmentInterface);
}

-(void)dealloc
{
    NSLog(@"%@销毁了",self);
}

@end


text:
package com.github.obourgain.elasticsearch.http.handler.search.multipercolate;

import static org.elasticsearch.common.xcontent.XContentParser.Token.START_ARRAY;
import java.io.IOException;
import java.util.List;
import org.elasticsearch.common.bytes.BytesReference;
import org.elasticsearch.common.xcontent.XContentHelper;
import org.elasticsearch.common.xcontent.XContentParser;
import com.github.obourgain.elasticsearch.http.buffer.ByteBufBytesReference;
import com.github.obourgain.elasticsearch.http.handler.document.multiget.Eithers;
import com.github.obourgain.elasticsearch.http.handler.search.percolate.PercolateResponse;
import io.netty.buffer.ByteBuf;
import lombok.Getter;
import rx.Observable;

@Getter
public class MultiPercolateResponse {
    private Eithers<MultiPercolateResponseError, PercolateResponse> responses = new Eithers<>();

    public List<MultiPercolateResponseError> errors() {
        return responses.lefts();
    }

    public List<PercolateResponse> percolated() {
        return responses.rights();
    }

    public Eithers<MultiPercolateResponseError, PercolateResponse> all() {
        return responses;
    }

    protected static Observable<MultiPercolateResponse> parse(ByteBuf content) {
        return Observable.just(new MultiPercolateResponse().doParse(new ByteBufBytesReference(content)));
    }

    protected MultiPercolateResponse doParse(BytesReference bytesReference) {
        try (XContentParser parser = XContentHelper.createParser(bytesReference)) {
            XContentParser.Token token;
            String currentFieldName = null;
            while ((token = parser.nextToken()) != XContentParser.Token.END_OBJECT) {
                if (token == XContentParser.Token.FIELD_NAME) {
                    currentFieldName = parser.currentName();
                } else if (token.isValue()) {
                    assert currentFieldName != null;
                } else if (token == XContentParser.Token.START_ARRAY) {
                    if ("responses".equals(currentFieldName)) {
                        parseDocs(parser);
                    }
                }
            }
            return this;
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }

    protected MultiPercolateResponse parseDocs(XContentParser parser) throws IOException {
        assert parser.currentToken() == START_ARRAY : "expected a START_ARRAY token but was " + parser.currentToken();
        XContentParser.Token token;
        String currentFieldName = null;
        while ((token = parser.nextToken()) != XContentParser.Token.END_ARRAY) {
            if (token == XContentParser.Token.FIELD_NAME) {
                currentFieldName = parser.currentName();
            } else if (token.isValue()) {
                assert currentFieldName != null;
            } else if (token == XContentParser.Token.START_OBJECT) {
                responses.add(PercolateResponse.doParse(parser));
            }
        }
        return this;
    }
}


text:
/**
 * @author cdr
 */
package com.intellij.psi.controlFlow;

import com.intellij.openapi.diagnostic.Logger;

public abstract class SimpleInstruction extends InstructionBase {
  private static final Logger LOG = Logger.getInstance("#com.intellij.psi.controlFlow.SimpleInstruction");

  @Override
  public int nNext() { return 1; }

  @Override
  public int getNext(int index, int no) {
    LOG.assertTrue(no == 0);
    return index + 1;
  }

  @Override
  public void accept(ControlFlowInstructionVisitor visitor, int offset, int nextOffset) {
    visitor.visitSimpleInstruction(this, offset, nextOffset);
  }
}


text:
export const localizationText = {
  greek: {
    amount: 'Ποσό',
    transactionExecution: 'Εκτέλεση Συναλλαγής',
  },
  english: {
    amount: 'Amount',
    transactionExecution: 'Transaction Execution',
  }
}

export default localizationText


text:
<!DOCTYPE HTML>

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X

X


text:
Sagey is a WordPress starter plugin for projects with/without a front-end developement component and with/without a settings page. It includes an optional, slightly customized, namespaced version of [Cheezcap](https://github.com/alcandelario/cheezcap) to easily create a "Settings" page

## Why?

* If you'd like a plugin to load your theme's CSS/JS rather than put that logic directly in the theme.
* If you'd like to override a theme's CSS/JS/templates with your own, rather than modifying the theme directly
* If you'd like to create a settings page for a plugin or theme but don't want to modify the the theme directly

## New Features

* [gulp](http://gulpjs.com/) build script with two new additions: do not minify assets unless running gulp --production. Wrap all minified JavaScript in an IIFE to protect variable scope. Run "gulp namespace" to change all namespaced .php files to whatever namespace is defined in /assets/manifest.json

* [Cheezcap](https://github.com/alcandelario/cheezcap) with support for two new option types, MultiSelect (saved as serialized string) and MediaItem (selects content from media library).

## Plugin installation

Bottom line is you want to get the files in this repo into your local development environment's wp-content/plugins folder

## Plugin setup

* Edit `./assets/manifest.json` to set the namespace, include vendor JS/CSS if necessary, and change gulp output paths.
* Edit `./constants.php` as needed. Some constants also have the current namespace in them, but that's not required - you can name them whatever you like
  * `LOAD_ASSETS` - whether or not to enqueue the CSS/JS
  * `USE_ADMIN_MENU` - creates a link in the WP admin area for your plugin
  * `INIT_OPTIONS_PAGE` - creates a link to a cheezcap options page
  * `OPTIONS_AS_SUBMENU` - either creates the cheezcap options page as a top-level page, or a sub-page. Set to FALSE when your plugin only needs a settings page
* Run `gulp namespace` to automatically update the namespace everywhere used, so we don't collide with other instances of the Sagey plugin
* Run `gulp` to build the /dist folder
* Or just run `gulp watch` if working with CSS/JS files and upon change, the /dist folder will be built

## Default Plugin Features

Upon activation, the Sagey Starter Plugin will:
* Register a wp_enqueue_scripts/wp_enqueue_styles for the plugin, the assets for which are compiled by gulp and put in /dist
* Register hook for creating an admin menu item and page
* Register hook to create an admin submenu item and page for managing plugin settings

### Available gulp commands

* `gulp` — Compile and optimize the files in your assets directory
* `gulp watch` — Compile assets when file changes are made (no minification of js)
* `gulp --production` — Compile assets for production (no source maps).
* `gulp namespace` - finds all .php files and changes the namespace where applicable


text:
package de.itech.borad.client.chat;

import de.itech.borad.core.KeyStore;
import de.itech.borad.core.MessageController;
import de.itech.borad.core.StateManager;
import de.itech.borad.models.BaseMessage;
import de.itech.borad.models.Message;
import de.itech.borad.models.User;
import javafx.scene.control.ScrollPane;
import javafx.scene.layout.VBox;

import javax.swing.*;
import java.security.Key;
import java.util.Date;

public class ChatPanel extends ScrollPane {
    private final VBox messages = new VBox(5);

    private ChatInput chatInput;

    public ChatPanel(MessageController controller) {

        chatInput = new ChatInput(this, controller);

        this.getStyleClass().add("chat-panel");

        this.setContent(this.messages);
        this.setBackground(null);

    }

    /**
     * Add a message to this panel. The message is converted to a ChatBubble and added to the list of
     * children of this panel.
     * @param message The message to add to this panel.
     */
    public synchronized void addMessage(Message message) {
        if (message == null) throw new NullPointerException("The message to add to the panel can not be null");

        final ChatBubble bubble = new ChatBubble(message, false);
        bubble.prefWidthProperty().bind(this.widthProperty().subtract(11));

        this.messages.getChildren().add(bubble);

        this.setVvalue(1.0);
        this.messages.layout();
    }

    public synchronized void addOwnMessage(String value){
        Message message = new Message();
        message.setUser(new User(StateManager.getStateManager().getOwnName(), KeyStore.getInstance().getPublicKey()));
        message.setText(value);
        message.setTimestamp(new Date());

        final ChatBubble bubble = new ChatBubble(message, true);
        bubble.prefWidthProperty().bind(this.widthProperty().subtract(11));

        this.messages.getChildren().add(bubble);
        this.setVvalue(1.0);

        this.messages.layout();
    }

    public ChatInput getChatInput() {
        return chatInput;
    }
}


text:
<?xml version="1.0" encoding="utf-8"?>
<products xmlns:xlink="http://www.w3.org/1999/xlink">
   <latestpdf>MidoNet_Quick_Start_Guide_RHEL-7_Kilo-RDO_EN_5.0-rev4-latest.pdf</latestpdf>
   <pdfoutname>MidoNet_Quick_Start_Guide_RHEL-7_Kilo-RDO_EN_5.0-rev4.pdf</pdfoutname>
   <docname>MidoNet Quick Start Guide for RHEL 7 / Kilo (RDO)</docname>
   <productname>MidoNet Quick Start Guide</productname>
   <webappname>quick-start-guide/rhel-7_kilo-rdo_en</webappname>
   <pominfo>
      <groupid>org.midonet</groupid>
      <artifactid>midonet-docs-quick-start-guide-rhel-7-kilo-rdo-en</artifactid>
      <version>5.0-rev4</version>
      <pomname>midonet-docs-quick-start-guide-rhel-7-kilo-rdo-en v5.0-rev4</pomname>
   </pominfo>
</products>


text:
package io.fabric8.mq.core;

import org.apache.activemq.ActiveMQConnectionFactory;

/**
 * A replacement for the {@link ActiveMQConnectionFactory} which is configured with the
 * Kubernetes service name {@link #setServiceName(String)} to connect to different broker groups
 * and it then discovers the broker to connect to via Kubernetes services.
 */
public class MQConnectionFactory extends ActiveMQConnectionFactory {
    private String serviceName;
    private String failoverUrlParameters;

    public MQConnectionFactory() {
    }

    public MQConnectionFactory(String userName, String password) {
        this();
        setUserName(userName);
        setPassword(password);
    }

    @Override
    public String getBrokerURL() {
        return MQs.getBrokerURL(getServiceName(), getFailoverUrlParameters());
    }

    @Override
    public void setBrokerURL(String brokerURL) {
        throw new UnsupportedOperationException("brokerURL property cannot be modified for this component. Please modify the serviceName instead!");
    }

    public String getServiceName() {
        return serviceName;
    }

    /**
     * Sets the Kubernetes service name used to resolve against the $serviceName_SERVICE_HOST and
     * $serviceName_SERVICE_PORT environment variables to find the broker group to connect t.
     */
    public void setServiceName(String serviceName) {
        this.serviceName = serviceName;
    }

    public String getFailoverUrlParameters() {
        return failoverUrlParameters;
    }

    /**
     * Allows any failover parameters to be specified after the failover://host:port/ part of the brokerURL.
     */
    public void setFailoverUrlParameters(String failoverUrlParameters) {
        this.failoverUrlParameters = failoverUrlParameters;
    }
}


text:
ACCEPTED

#### According to
Index Fungorum

#### Published in
Syll. fung. (Abellini) 5: 54 (1887)

#### Original name
Agaricus cuculliformis Fr.

### Remarks
null


text:
namespace Rhythm.ImportIPLocationData
{
    partial class frmMain
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Windows Form Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmMain));
            this.btnImport = new System.Windows.Forms.Button();
            this.tableMain = new System.Windows.Forms.TableLayoutPanel();
            this.txtConnection = new System.Windows.Forms.TextBox();
            this.richInstructions = new System.Windows.Forms.RichTextBox();
            this.label1 = new System.Windows.Forms.Label();
            this.label2 = new System.Windows.Forms.Label();
            this.tableLayoutPanel2 = new System.Windows.Forms.TableLayoutPanel();
            this.txtBlocks = new System.Windows.Forms.TextBox();
            this.btnPickBlocks = new System.Windows.Forms.Button();
            this.tableLayoutPanel3 = new System.Windows.Forms.TableLayoutPanel();
            this.txtLocation = new System.Windows.Forms.TextBox();
            this.btnPickLocation = new System.Windows.Forms.Button();
            this.label3 = new System.Windows.Forms.Label();
            this.tableLayoutPanel4 = new System.Windows.Forms.TableLayoutPanel();
            this.progressImport = new System.Windows.Forms.ProgressBar();
            this.tableMain.SuspendLayout();
            this.tableLayoutPanel2.SuspendLayout();
            this.tableLayoutPanel3.SuspendLayout();
            this.tableLayoutPanel4.SuspendLayout();
            this.SuspendLayout();
            //
            // btnImport
            //
            this.btnImport.Anchor = System.Windows.Forms.AnchorStyles.Right;
            this.btnImport.AutoSize = true;
            this.btnImport.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
            this.btnImport.Location = new System.Drawing.Point(709, 3);
            this.btnImport.Name = "btnImport";
            this.btnImport.Size = new System.Drawing.Size(46, 23);
            this.btnImport.TabIndex = 0;
            this.btnImport.Text = "Import";
            this.btnImport.UseVisualStyleBackColor = true;
            this.btnImport.Click += new System.EventHandler(this.btnImport_Click);
            //
            // tableMain
            //
            this.tableMain.ColumnCount = 2;
            this.tableMain.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
            this.tableMain.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableMain.Controls.Add(this.txtConnection, 1, 3);
            this.tableMain.Controls.Add(this.richInstructions, 0, 0);
            this.tableMain.Controls.Add(this.label1, 0, 1);
            this.tableMain.Controls.Add(this.label2, 0, 2);
            this.tableMain.Controls.Add(this.tableLayoutPanel2, 1, 1);
            this.tableMain.Controls.Add(this.tableLayoutPanel3, 1, 2);
            this.tableMain.Controls.Add(this.label3, 0, 3);
            this.tableMain.Controls.Add(this.tableLayoutPanel4, 0, 4);
            this.tableMain.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableMain.Location = new System.Drawing.Point(0, 0);
            this.tableMain.Name = "tableMain";
            this.tableMain.RowCount = 5;
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle());
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle());
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle());
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle());
            this.tableMain.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F));
            this.tableMain.Size = new System.Drawing.Size(764, 362);
            this.tableMain.TabIndex = 1;
            //
            // txtConnection
            //
            this.txtConnection.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
            this.txtConnection.Location = new System.Drawing.Point(100, 304);
            this.txtConnection.Name = "txtConnection";
            this.txtConnection.Size = new System.Drawing.Size(661, 20);
            this.txtConnection.TabIndex = 6;
            this.txtConnection.Text = "server=some-server;database=some-database;user id=some-user;password=some-passwor" +
    "d";
            //
            // richInstructions
            //
            this.tableMain.SetColumnSpan(this.richInstructions, 2);
            this.richInstructions.Dock = System.Windows.Forms.DockStyle.Fill;
            this.richInstructions.Location = new System.Drawing.Point(3, 3);
            this.richInstructions.Name = "richInstructions";
            this.richInstructions.ReadOnly = true;
            this.richInstructions.Size = new System.Drawing.Size(758, 225);
            this.richInstructions.TabIndex = 0;
            this.richInstructions.Text = resources.GetString("richInstructions.Text");
            this.richInstructions.LinkClicked += new System.Windows.Forms.LinkClickedEventHandler(this.richInstructions_LinkClicked);
            //
            // label1
            //
            this.label1.Anchor = System.Windows.Forms.AnchorStyles.Left;
            this.label1.AutoSize = true;
            this.label1.Location = new System.Drawing.Point(3, 242);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(63, 13);
            this.label1.TabIndex = 1;
            this.label1.Text = "Blocks CSV";
            //
            // label2
            //
            this.label2.Anchor = System.Windows.Forms.AnchorStyles.Left;
            this.label2.AutoSize = true;
            this.label2.Location = new System.Drawing.Point(3, 277);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(72, 13);
            this.label2.TabIndex = 2;
            this.label2.Text = "Location CSV";
            //
            // tableLayoutPanel2
            //
            this.tableLayoutPanel2.AutoSize = true;
            this.tableLayoutPanel2.ColumnCount = 2;
            this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel2.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
            this.tableLayoutPanel2.Controls.Add(this.txtBlocks, 0, 0);
            this.tableLayoutPanel2.Controls.Add(this.btnPickBlocks, 1, 0);
            this.tableLayoutPanel2.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanel2.Location = new System.Drawing.Point(100, 234);
            this.tableLayoutPanel2.Name = "tableLayoutPanel2";
            this.tableLayoutPanel2.RowCount = 1;
            this.tableLayoutPanel2.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel2.Size = new System.Drawing.Size(661, 29);
            this.tableLayoutPanel2.TabIndex = 3;
            //
            // txtBlocks
            //
            this.txtBlocks.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
            this.txtBlocks.Location = new System.Drawing.Point(3, 4);
            this.txtBlocks.Name = "txtBlocks";
            this.txtBlocks.Size = new System.Drawing.Size(623, 20);
            this.txtBlocks.TabIndex = 0;
            //
            // btnPickBlocks
            //
            this.btnPickBlocks.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
            this.btnPickBlocks.AutoSize = true;
            this.btnPickBlocks.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
            this.btnPickBlocks.Location = new System.Drawing.Point(632, 3);
            this.btnPickBlocks.Name = "btnPickBlocks";
            this.btnPickBlocks.Size = new System.Drawing.Size(26, 23);
            this.btnPickBlocks.TabIndex = 1;
            this.btnPickBlocks.Text = "...";
            this.btnPickBlocks.UseVisualStyleBackColor = true;
            this.btnPickBlocks.Click += new System.EventHandler(this.btnPickBlocks_Click);
            //
            // tableLayoutPanel3
            //
            this.tableLayoutPanel3.AutoSize = true;
            this.tableLayoutPanel3.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
            this.tableLayoutPanel3.ColumnCount = 2;
            this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel3.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
            this.tableLayoutPanel3.Controls.Add(this.txtLocation, 0, 0);
            this.tableLayoutPanel3.Controls.Add(this.btnPickLocation, 1, 0);
            this.tableLayoutPanel3.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanel3.Location = new System.Drawing.Point(100, 269);
            this.tableLayoutPanel3.Name = "tableLayoutPanel3";
            this.tableLayoutPanel3.RowCount = 1;
            this.tableLayoutPanel3.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel3.Size = new System.Drawing.Size(661, 29);
            this.tableLayoutPanel3.TabIndex = 4;
            //
            // txtLocation
            //
            this.txtLocation.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
            this.txtLocation.Location = new System.Drawing.Point(3, 4);
            this.txtLocation.Name = "txtLocation";
            this.txtLocation.Size = new System.Drawing.Size(623, 20);
            this.txtLocation.TabIndex = 0;
            //
            // btnPickLocation
            //
            this.btnPickLocation.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Right)));
            this.btnPickLocation.AutoSize = true;
            this.btnPickLocation.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
            this.btnPickLocation.Location = new System.Drawing.Point(632, 3);
            this.btnPickLocation.Name = "btnPickLocation";
            this.btnPickLocation.Size = new System.Drawing.Size(26, 23);
            this.btnPickLocation.TabIndex = 1;
            this.btnPickLocation.Text = "...";
            this.btnPickLocation.UseVisualStyleBackColor = true;
            this.btnPickLocation.Click += new System.EventHandler(this.btnPickLocation_Click);
            //
            // label3
            //
            this.label3.Anchor = System.Windows.Forms.AnchorStyles.Left;
            this.label3.AutoSize = true;
            this.label3.Location = new System.Drawing.Point(3, 307);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(91, 13);
            this.label3.TabIndex = 5;
            this.label3.Text = "Connection String";
            //
            // tableLayoutPanel4
            //
            this.tableLayoutPanel4.AutoSize = true;
            this.tableLayoutPanel4.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
            this.tableLayoutPanel4.ColumnCount = 2;
            this.tableMain.SetColumnSpan(this.tableLayoutPanel4, 2);
            this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel4.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle());
            this.tableLayoutPanel4.Controls.Add(this.btnImport, 1, 0);
            this.tableLayoutPanel4.Controls.Add(this.progressImport, 0, 0);
            this.tableLayoutPanel4.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanel4.Location = new System.Drawing.Point(3, 330);
            this.tableLayoutPanel4.Name = "tableLayoutPanel4";
            this.tableLayoutPanel4.RowCount = 1;
            this.tableLayoutPanel4.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanel4.Size = new System.Drawing.Size(758, 29);
            this.tableLayoutPanel4.TabIndex = 7;
            //
            // progressImport
            //
            this.progressImport.Dock = System.Windows.Forms.DockStyle.Fill;
            this.progressImport.Location = new System.Drawing.Point(3, 3);
            this.progressImport.MarqueeAnimationSpeed = 300;
            this.progressImport.Maximum = 1000;
            this.progressImport.Name = "progressImport";
            this.progressImport.Size = new System.Drawing.Size(700, 23);
            this.progressImport.Style = System.Windows.Forms.ProgressBarStyle.Continuous;
            this.progressImport.TabIndex = 1;
            //
            // frmMain
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(764, 362);
            this.Controls.Add(this.tableMain);
            this.Name = "frmMain";
            this.Text = "Import IP Location Data";
            this.tableMain.ResumeLayout(false);
            this.tableMain.PerformLayout();
            this.tableLayoutPanel2.ResumeLayout(false);
            this.tableLayoutPanel2.PerformLayout();
            this.tableLayoutPanel3.ResumeLayout(false);
            this.tableLayoutPanel3.PerformLayout();
            this.tableLayoutPanel4.ResumeLayout(false);
            this.tableLayoutPanel4.PerformLayout();
            this.ResumeLayout(false);

        }

        #endregion

        private System.Windows.Forms.Button btnImport;
		private System.Windows.Forms.TableLayoutPanel tableMain;
		private System.Windows.Forms.RichTextBox richInstructions;
		private System.Windows.Forms.Label label1;
		private System.Windows.Forms.Label label2;
		private System.Windows.Forms.TableLayoutPanel tableLayoutPanel2;
		private System.Windows.Forms.TextBox txtBlocks;
		private System.Windows.Forms.Button btnPickBlocks;
		private System.Windows.Forms.TableLayoutPanel tableLayoutPanel3;
		private System.Windows.Forms.TextBox txtLocation;
		private System.Windows.Forms.Button btnPickLocation;
        private System.Windows.Forms.Label label3;
        private System.Windows.Forms.TextBox txtConnection;
        private System.Windows.Forms.TableLayoutPanel tableLayoutPanel4;
        private System.Windows.Forms.ProgressBar progressImport;
    }
}


text:
<?php
namespace Application\Entity;
use Doctrine\ORM\Mapping as ORM;

/** @ORM\Entity */
class User {
	/**
	* @ORM\Id
	* @ORM\GeneratedValue(strategy='AUTO')
	* @ORM\Column(type="integer")
	*/
	protected $id;

	/** @ORM\Column(type="string") */
	protected $fullName;

	//getters/setters

    /**
     * Gets the value of fullName.
     *
     * @return mixed
     */
    public function getFullName()
    {
        return $this->fullName;
    }

    /**
     * Sets the value of fullName.
     *
     * @param mixed $fullName the full name
     *
     * @return self
     */
    public function setFullName($fullName)
    {
        $this->fullName = $fullName;

        return $this;
    }
}


text:
using Newtonsoft.Json;

namespace Typeform.Dotnet.Data
{
    public class FormStats
    {
        [JsonProperty("responses")]
        public ResponsesStats ResponseStats { get; set; }
    }
}


text:
        Enable Enhanced Logging

    If this option is enabled, the console output of the remote job is also logged.

        mandatory: no

        default: false


text:
Collects metrics from one or more instances of Redis databases.

### Prerequisites

|     OS    | Linux | Windows | SmartOS | OS X |
|:----------|:-----:|:-------:|:-------:|:----:|
| Supported |   v   |         |         |      |

This plugin is compatible with Redis 2.6.X or later.

#### For TrueSight Meter v4.2 or later

- To install new meter go to Settings->Installation or [see instructions](https://help.truesight.bmc.com/hc/en-us/sections/200634331-Installation).
- To upgrade the meter to the latest version - [see instructions](https://help.truesight.bmc.com/hc/en-us/articles/201573102-Upgrading-the-Boundary-Meter).

#### For Truesight Meter earlier than v4.2

|  Runtime | node.js | Python | Java |
|:---------|:-------:|:------:|:----:|
| Required |    v    |        |      |

- [How to install node.js?](https://help.boundary.com/hc/articles/202360701)

### Plugin Setup

None

### Plugin Configuration Fields

|Field Name  |Description                                            |
|:-----------|:------------------------------------------------------|
|Host        |The redis hostname.                                    |
|Port        |The redis port.                                        |
|Password    |Password to the redis server.                          |
|PollInterval|Interval (in milliseconds) to query the redis server.  |
|Source      |The source to display in the legend for the REDIS data.|

### Metrics Collected

|Metric Name               |Description|
|:-------------------------|:---------------------------------------------------------------|
|Redis Connected Clients   |Number of client connections (excluding connections from slaves)|
|Redis Key Hits            |Number of successful lookup of keys in the main dictionary      |
|Redis Key Misses          |Number of failed lookup of keys in the main dictionary          |
|Redis Keys Expired        |Total number of key expiration events                           |
|Redis Key Evictions       |Number of evicted keys due to maxmemory limit                   |
|Redis Connections Received|Total number of connections accepted by the server              |
|Redis Commands Processed  |Total number of commands processed by the server                |
|Redis Used Memory         |Percentage of server memory used for the Redis instance         |

### Dashboards

- Redis

### References

See information on Redis `INFO` command [here](http://redis.io/commands/info)


text:
These scripts are primarily meant to support the use of
[Janky](https://github.com/github/janky). To use them, read the contents of this
repository into a `script` folder:

```
$ git remote add objc-build-scripts https://github.com/jspahrsummers/objc-build-scripts.git
$ git fetch objc-build-scripts
$ git read-tree --prefix=script/ -u objc-build-scripts/master
```

Then commit the changes to incorporate the scripts into your own repository's
history. You can also freely tweak the scripts for your specific project's
needs.

To bring in upstream changes later:

```
$ git fetch -p objc-build-scripts
$ git merge -Xsubtree=script objc-build-scripts/master
```


text:
package org.apache.eagle.alert.engine.coordinator;

import java.io.Serializable;
import java.util.HashSet;
import java.util.Set;

import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.builder.HashCodeBuilder;

import com.fasterxml.jackson.annotation.JsonIgnore;
import com.google.common.base.Objects;

public class PublishPartition implements Serializable {

    private static final long serialVersionUID = 2524776632955586234L;

    private String policyId;
    private String streamId;
    private String publishId;
    private Set<String> columns = new HashSet<>();

    @JsonIgnore
    private Set<Object> columnValues = new HashSet<>();

    public PublishPartition() {
    }

    public PublishPartition(String streamId, String policyId, String publishId, Set<String> columns) {
        this.streamId = streamId;
        this.policyId = policyId;
        this.publishId = publishId;
        if (columns != null) {
            this.columns = columns;
        }
    }

    @Override
    public int hashCode() {
        return new HashCodeBuilder().append(streamId).append(policyId).append(publishId).append(columns).append(columnValues).build();
    }

    @Override
    public boolean equals(Object obj) {
        return obj instanceof PublishPartition
            && Objects.equal(this.streamId, ((PublishPartition) obj).getStreamId())
            && Objects.equal(this.policyId, ((PublishPartition) obj).getPolicyId())
            && Objects.equal(this.publishId, ((PublishPartition) obj).getPublishId())
            && CollectionUtils.isEqualCollection(this.columns, ((PublishPartition) obj).getColumns())
            && CollectionUtils.isEqualCollection(this.columnValues, ((PublishPartition) obj).getColumnValues());
    }

    @Override
    public String toString() {
        return String.format("PublishPartition[policyId=%s,streamId=%s,publishId=%s,columns=%s,columnValues=%s]",
            policyId, streamId, publishId, columns, columnValues);
    }

    @Override
    public PublishPartition clone() {
        return new PublishPartition(this.streamId, this.policyId, this.publishId, new HashSet<>(this.columns));
    }

    public String getPolicyId() {
        return policyId;
    }

    public void setPolicyId(String policyId) {
        this.policyId = policyId;
    }

    public String getStreamId() {
        return streamId;
    }

    public void setStreamId(String streamId) {
        this.streamId = streamId;
    }

    public String getPublishId() {
        return publishId;
    }

    public void setPublishId(String publishId) {
        this.publishId = publishId;
    }

    public Set<String> getColumns() {
        return columns;
    }

    public void setColumns(Set<String> columns) {
        this.columns = columns;
    }

    @JsonIgnore
    public Set<Object> getColumnValues() {
        return columnValues;
    }

    @JsonIgnore
    public void setColumnValues(Set<Object> columnValues) {
        this.columnValues = columnValues;
    }

}