text:
/*
 * dns_cache.c
 *
 * Cache of DNS entries
 *
 * Mike Belshe
 * 02-03-96
 */

#include "netsite.h"
#include "time/nstime.h"
#include "base/cache.h"
#include "base/dns_cache.h"
#include "base/buffer.h"
#include "base/ereport.h"
#include "base/util.h"
#include "base/daemon.h"
#include "base/dbtbase.h"

/* ----- Forwards ----------------------------------------------------- */
static unsigned int dns_cache_hash_ip(unsigned int, void *);
static int dns_cache_compare_keys(void *, void *);
static int dns_cache_cleanup(void *);
static int dns_cache_debug(pblock *pb, Session *sn, Request *rq);
static int dns_cache_print(void *data, SYS_NETFD fd);

/* ----- Static globals ----------------------------------------------- */
static cache_t			*dns_cache = NULL;
static unsigned long		dns_expire_time = 0;

static	public_cache_functions_t dns_cache_functions = {
		dns_cache_hash_ip,
		dns_cache_debug
	};

static	cache_entry_functions_t dns_cache_entry_functions = {
		dns_cache_compare_keys,
		dns_cache_cleanup,
		dns_cache_print
	};

/* ----- Functions ----------------------------------------------------- */

static unsigned int
dns_cache_hash_ip(unsigned int hash_size, void *voidint)
{
	register unsigned int *intptr = (unsigned int *)voidint;

	return (*intptr) % hash_size;
}

static int
dns_cache_compare_keys(void *voidint1, void *voidint2)
{
	return  !( *(unsigned int *)voidint1 == *(unsigned int *)voidint2);
}

static int
dns_cache_cleanup(void *voiddata)
{
	dns_cache_entry_t *data = (dns_cache_entry_t *)voiddata;

	if (!dns_cache || !data)
		return -1;

	if (data->host)
		PERM_FREE(data->host);

	/* It is imperative that we do not FREE the dns_cache_entry_t (data)
     * structure here.  cache_delete() will do that for us.
     */

	return 0;
}

static int
dns_cache_debug(pblock *pb, Session *sn, Request *rq)
{
	if (!dns_cache)
		return 0;

	return cache_dump(dns_cache, "DNS Cache", sn->csd);
}

#define MAX_DEBUG_LINE	1024
static int
dns_cache_print(void *voiddata, SYS_NETFD fd)
{
#ifdef DEBUG_CACHES	/* XXXhep this causes ball of string effect */
	dns_cache_entry_t *data = (dns_cache_entry_t *)voiddata;
	char buf[MAX_DEBUG_LINE];
	int len;

	if (!dns_cache || !data)
		return 0;

	len = util_snprintf(buf, MAX_DEBUG_LINE,  "%s %d\n",
		data->host?data->host:"null", data->ip);
	net_write(fd, buf,len);
#endif /* DEBUG_CACHES */

	return 0;
}

NSAPI_PUBLIC int
dns_cache_init(int dns_cache_size, int timeout)
{
	/* Check if cache already initialized */
	if (dns_cache)
		return -1;

	dns_expire_time = timeout;

	if ( (dns_cache = cache_create(dns_cache_size, 2*dns_cache_size,
		&dns_cache_functions)) ==NULL){
		return -1;
	}

	return 0;
}

NSAPI_PUBLIC void
dns_cache_destroy(cache_t *cache)
{
	/* cache module automatically cleans up the cache itself */
	dns_cache = NULL;
}

NSAPI_PUBLIC dns_cache_entry_t *
dns_cache_insert(char *host, unsigned int ip, unsigned int verified)
{
	dns_cache_entry_t *newentry;

	if ( !dns_cache || !ip)  {
		return NULL;
    }

	if ( (newentry = (dns_cache_entry_t *)PERM_MALLOC(sizeof(dns_cache_entry_t))) == NULL) {
		ereport(LOG_FAILURE, XP_GetAdminStr(DBT_dnsCacheInsertErrorAllocatingEnt_));
		goto error;
	}

	if (host) {
		if ( (newentry->host = PERM_STRDUP(host)) == NULL) {
			ereport(LOG_FAILURE, XP_GetAdminStr(DBT_dnsCacheInsertMallocFailure_));
			goto error;
		}
	} else
		newentry->host = NULL;

#ifdef CACHE_DEBUG
	newentry->cache.magic = CACHE_ENTRY_MAGIC;
#endif

	newentry->ip = ip;
	newentry->verified = verified;

	newentry->last_access = ft_time();

	if ( cache_insert_p(dns_cache, &(newentry->cache), (void *)&(newentry->ip),
		(void *)newentry, &dns_cache_entry_functions) < 0) {
		/* Not a bad error; it just means the cache is full */
		goto error;
	}

	return newentry;

error:
	if (newentry) {
		if (newentry->host)
			PERM_FREE(newentry->host);
		PERM_FREE(newentry);
	}
	return NULL;
}

NSAPI_PUBLIC int
dns_cache_delete(void *entry)
{
	if ( !dns_cache || !entry )
		return -1;

	return cache_delete(dns_cache, (cache_entry_t *)entry, 0);
}

NSAPI_PUBLIC int
dns_cache_use_increment(void *entry)
{
	if ( !dns_cache || !entry )
		return -1;

	return cache_use_increment(dns_cache, (cache_entry_t *)entry);
}

NSAPI_PUBLIC int
dns_cache_use_decrement(void *entry)
{
	if ( !dns_cache || !entry)
		return -1;

	return cache_use_decrement(dns_cache, (cache_entry_t *)entry);
}

NSAPI_PUBLIC dns_cache_entry_t *
dns_cache_lookup_ip(unsigned int ip)
{
	dns_cache_entry_t *ptr;

	if (!dns_cache || !ip )
		return NULL;

	ptr = (dns_cache_entry_t *)cache_do_lookup(dns_cache, (void *)&ip);

	if (ptr) {
		if (dns_cache_valid(ptr) < 0) {
			if (dns_cache_delete(ptr) < 0)
				/* couldn't delete right now */
				dns_cache_use_decrement(ptr);
			return NULL;
		}

		(void)dns_cache_touch(ptr);
	}

	return ptr;
}

NSAPI_PUBLIC int
dns_cache_valid(dns_cache_entry_t *entry)
{
	time_t now;

	now = ft_time();

	if (now > (time_t)(entry->last_access + dns_expire_time))
		return -1;

	return cache_valid(dns_cache, (cache_entry_t *)entry);
}

NSAPI_PUBLIC int
dns_cache_touch(dns_cache_entry_t *entry)
{
	if (!entry)
		return -1;

	return cache_touch(dns_cache, (cache_entry_t *)entry);
}

#include "httpdaemon/internalstats.h"

PRBool
GetDNSCacheInfo(DNSCacheInfo *info)
{
    if (!info)
        return PR_FALSE;

    memset(info, 0, sizeof(DNSCacheInfo));

    info->enabled = (dns_cache == NULL)?PR_FALSE:PR_TRUE;

    if (info->enabled) {
        info->maxCacheEntries = dns_cache->max_size;
        info->numCacheEntries = dns_cache->cache_size;

        info->numCacheHits = dns_cache->cache_hits;
        info->numCacheMisses = dns_cache->cache_lookups - dns_cache->cache_hits;

        info->numCacheInsertsOk = dns_cache->insert_ok;
        info->numCacheInsertsFail = dns_cache->insert_fail;
        info->numCacheDeletes = dns_cache->deletes;
    }

    return PR_TRUE;
}


text:
<?php

// Please note it is recommended to use the subtag [pt-BR], not [pr_BR]
// That is the one formalized by the W3C in the IANA Language Subtag Registry
// - https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry
// - https://www.w3.org/International/questions/qa-choosing-language-tags
//
// Also, that is the one used by the most popular Laravel translation package
// - https://github.com/caouecs/Laravel-lang/tree/master/src
//
// Backpack provides translations for both subtags, for backwards compatibility.
// But this will change at some point, and we will only support [pt-BR].

return [
    /*
    |--------------------------------------------------------------------------
    | Backpack\Base Language Lines
    |--------------------------------------------------------------------------
    */
    'registration_closed'    => 'Novos registros estão desabiltados.',
    'no_email_column'        => 'Usuários não possuem um endereço de email associado.',
    'first_page_you_see'     => 'A primeira página que você vê depois de logar',
    'login_status'           => 'Status do login',
    'logged_in'              => 'Você está logado!',
    'toggle_navigation'      => 'Alternar navegação',
    'administration'         => 'ADMINISTRAÇÃO',
    'user'                   => 'USUÁRIO',
    'logout'                 => 'Logout',
    'login'                  => 'Login',
    'register'               => 'Registrar',
    'name'                   => 'Nome',
    'email_address'          => 'E-Mail',
    'password'               => 'Senha',
    'old_password'           => 'Senha antiga',
    'new_password'           => 'Nova senha',
    'confirm_password'       => 'Confirmar senha',
    'remember_me'            => 'Manter-me logado',
    'forgot_your_password'   => 'Esqueci minha senha',
    'reset_password'         => 'Resetar senha',
    'send_reset_link'        => 'Enviar link de recuperação de senha',
    'click_here_to_reset'    => 'Clique aqui para resetar sua senha',
    'change_password'        => 'Mudar senha',
    'unauthorized'           => 'Sem autorização.',
    'dashboard'              => 'Dashboard',
    'handcrafted_by'         => 'Feito por',
    'powered_by'             => 'Distribuído por',
    'my_account'             => 'Minha conta',
    'update_account_info'    => 'Atualizar minha conta',
    'save'                   => 'Salvar',
    'cancel'                 => 'Cancelar',
    'error'                  => 'Erro',
    'success'                => 'Sucesso',
    'warning'                => 'Atenção',
    'notice'                 => 'Aviso',
    'old_password_incorrect' => 'A senha antiga está incorreta.',
    'password_dont_match'    => 'Senhas não são iguais.',
    'password_empty'         => 'Certifique-se que ambos os campos de senha estão preenchidos.',
    'password_updated'       => 'Senha atualizada.',
    'account_updated'        => 'Conta atualizada com sucesso.',
    'unknown_error'          => 'Um erro desconhecido aconteceu. Por favor, tente novamente.',
    'error_saving'           => 'Erro ao salvar. Por favor, tente novamente.',
    'welcome'                => 'Bem vindo!',
    'use_sidebar'            => 'Use a barra de menu à esquerda para criar, editar ou excluir conteúdo.',
    'password_reset'         => [
        'greeting' => 'Olá!',
        'subject'  => 'Notificação de redefinição de senha',
        'line_1'   => 'Você está recebendo este e-mail porque nós recebemos um solicitação de redefinição de senha para sua conta.',
        'line_2'   => 'Clique no botão abaixo para redefinir sua senha:',
        'button'   => 'Redefinir Senha',
        'notice'   => 'Se você não solicitou uma redefinição de senha, nenhuma ação adicional é necessária.',
    ],
    'step'                   => 'Passo',
    'confirm_email'          => 'Confirmar E-mail',
    'choose_new_password'    => 'Escolher Nova Senha',
    'confirm_new_password'   => 'Confirmar Nova senha',
];

redpajama_set_name: RedPajamaGithub


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

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Uses of Class net.sourceforge.pmd.lang.jsp.ast.JspParser (PMD 5.5.1 API)</title>
<meta name="date" content="2016-07-27">
<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

Next

Frames

No Frames

All Classes

Uses of Class
net.sourceforge.pmd.lang.jsp.ast.JspParser

Packages that use JspParser

Package
Description

net.sourceforge.pmd.lang.jsp.ast

Uses of JspParser in net.sourceforge.pmd.lang.jsp.ast

Fields in net.sourceforge.pmd.lang.jsp.ast declared as JspParser

Modifier and Type
Field and Description

protected JspParser
AbstractJspNode.parser

Constructors in net.sourceforge.pmd.lang.jsp.ast with parameters of type JspParser

Constructor and Description

AbstractJspNode(JspParser parser,
               int id)

ASTAttribute(JspParser p,
            int id)

ASTAttributeValue(JspParser p,
                 int id)

ASTCData(JspParser p,
        int id)

ASTCommentTag(JspParser p,
             int id)

ASTCompilationUnit(JspParser p,
                  int id)

ASTContent(JspParser p,
          int id)

ASTDeclaration(JspParser p,
              int id)

ASTDoctypeDeclaration(JspParser p,
                     int id)

ASTDoctypeExternalId(JspParser p,
                    int id)

ASTElement(JspParser p,
          int id)

ASTElExpression(JspParser p,
               int id)

ASTHtmlScript(JspParser p,
             int id)

ASTJspComment(JspParser p,
             int id)

ASTJspDeclaration(JspParser p,
                 int id)

ASTJspDeclarations(JspParser p,
                  int id)

ASTJspDirective(JspParser p,
               int id)

ASTJspDirectiveAttribute(JspParser p,
                        int id)

ASTJspDocument(JspParser p,
              int id)

ASTJspExpression(JspParser p,
                int id)

ASTJspExpressionInAttribute(JspParser p,
                           int id)

ASTJspScriptlet(JspParser p,
               int id)

ASTText(JspParser p,
       int id)

ASTUnparsedText(JspParser p,
               int id)

ASTValueBinding(JspParser p,
               int id)

Skip navigation links

Overview

Package

Class

Use

Tree

Deprecated

Index

Help

Prev

Next

Frames

No Frames

All Classes

Copyright © 2002–2016 InfoEther. All rights reserved.


text:
#pragma once
#include <aws/quicksight/QuickSight_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>

namespace Aws
{
namespace Utils
{
namespace Json
{
  class JsonValue;
  class JsonView;
} // namespace Json
} // namespace Utils
namespace QuickSight
{
namespace Model
{

  /**
   *
You don't have access to this item. The provided credentials couldn't be
   * validated. You might not be authorized to carry out the request. Make sure that
   * your account is authorized to use the Amazon QuickSight service, that your
   * policies have the correct permissions, and that you are using the correct access
   * keys.

See Also:
   AWS
   * API Reference

   */
  class AWS_QUICKSIGHT_API AccessDeniedException
  {
  public:
    AccessDeniedException();
    AccessDeniedException(Aws::Utils::Json::JsonView jsonValue);
    AccessDeniedException& operator=(Aws::Utils::Json::JsonView jsonValue);
    Aws::Utils::Json::JsonValue Jsonize() const;

    inline const Aws::String& GetMessage() const{ return m_message; }

    inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }

    inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; }

    inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); }

    inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); }

    inline AccessDeniedException& WithMessage(const Aws::String& value) { SetMessage(value); return *this;}

    inline AccessDeniedException& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;}

    inline AccessDeniedException& WithMessage(const char* value) { SetMessage(value); return *this;}

    /**
     *
The AWS request ID for this request.

     */
    inline const Aws::String& GetRequestId() const{ return m_requestId; }

    /**
     *
The AWS request ID for this request.

     */
    inline bool RequestIdHasBeenSet() const { return m_requestIdHasBeenSet; }

    /**
     *
The AWS request ID for this request.

     */
    inline void SetRequestId(const Aws::String& value) { m_requestIdHasBeenSet = true; m_requestId = value; }

    /**
     *
The AWS request ID for this request.

     */
    inline void SetRequestId(Aws::String&& value) { m_requestIdHasBeenSet = true; m_requestId = std::move(value); }

    /**
     *
The AWS request ID for this request.

     */
    inline void SetRequestId(const char* value) { m_requestIdHasBeenSet = true; m_requestId.assign(value); }

    /**
     *
The AWS request ID for this request.

     */
    inline AccessDeniedException& WithRequestId(const Aws::String& value) { SetRequestId(value); return *this;}

    /**
     *
The AWS request ID for this request.

     */
    inline AccessDeniedException& WithRequestId(Aws::String&& value) { SetRequestId(std::move(value)); return *this;}

    /**
     *
The AWS request ID for this request.

     */
    inline AccessDeniedException& WithRequestId(const char* value) { SetRequestId(value); return *this;}

  private:

    Aws::String m_message;
    bool m_messageHasBeenSet;

    Aws::String m_requestId;
    bool m_requestIdHasBeenSet;
  };

} // namespace Model
} // namespace QuickSight
} // namespace Aws


text:
require 'smesser/provider'

class O2Ie < Smesser::Provider
  @@start_url = "http://www.o2online.ie/o2/"
  @@send_action = "http://messaging.o2online.ie/smscenter_send.osp"
  @@send_delay = 2

  self.description = "www.o2.ie (400 free texts per month)"

  def logged_in?
    get @@start_url
    !!page.link_with(:text => 'Logout of o2.ie')
  end

  def login
    get(@@start_url)
    click('Login to o2.ie')
    post_form('o2login_form') do |form|
      form["IDToken1"] = @username
      form["IDToken2"] = @password
    end
  end

  def send(message, *recipients)
    get_webtext_page
    post_form('form_WebtextSend') do |form|
      form["SMSTo"] = recipients.join(", ")
      form["SMSText"] = message
      form.action = @@send_action
      sleep(@@send_delay)
    end
  end

  def remaining
    get_webtext_page
    if span = page.at("#spn_WebtextFree")
      span.inner_text
    else
      nil
    end
  end

  def get_webtext_page
    login unless logged_in?
    get(@@start_url)
    click('Send a webtext')
    get(page.frames.first.href)
  end
end
Smesser.providers['o2.ie'] = O2Ie


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;

namespace AecCloud.WebAPI.Models
{
    public class BadRequestResponseModel
    {
        public string Message { get; set; }

        public Dictionary<string, string[]> ModelState { get; set; }
        /// <summary>
        /// 反馈的错误信息
        /// </summary>
        /// <returns></returns>
        public string GetErrorMessage()
        {
            if (ModelState==null || ModelState.Count == 0) return Message;
            var errList = new List<string>();
            foreach (var k in ModelState)
            {
                errList.AddRange(k.Value);
            }
            if (errList.Count == 0) return Message;
            if (errList.Count == 1) return errList[0];
            return String.Join("\r\n", errList.ToArray());
        }
    }

    //public class ResponseModel
    //{
    //    public bool Success { get; set; }

    //    public HttpStatusCode Status { get; set; }

    //    public string Content { get; set; }
    //    /// <summary>
    //    /// Created状态码下需要
    //    /// </summary>
    //    public Uri Location { get; set; }

    //    //internal ResponseModel()
    //    //{
    //    //}
    //}
}


text:
/*-------------------------------------
zTree Style

version:	3.5.17
author:		Hunter.z
email:		hunter.z@263.net
website:	http://code.google.com/p/jquerytree/

-------------------------------------*/

.ztree * {padding:0; margin:0; font-size:13px; font-family: Verdana, Arial, Helvetica, AppleGothic, sans-serif}
.ztree {margin:0; padding:5px; color:#333}
.ztree li{padding:0; margin:0;  list-style:none; line-height:14px; text-align:left; white-space:nowrap; outline:0}
.ztree li ul{ margin:0; padding:0 0 0 18px}
.ztree li ul.line{ background:url(./img/line_conn.gif) 0 0 repeat-y;}

.ztree li a {padding:1px 3px 0 3px; /*padding:1px 3px 22px 0;*/ margin:0; margin-bottom: 5px; cursor:pointer; height:17px; color:#333; background-color: transparent;
	text-decoration:none; vertical-align:top; display: inline-block}
.ztree li a:hover {/*text-decoration:underline*/ background-color: #EEEEEE;text-decoration:none;}
.ztree li a.level0{  /*padding-bottom: 20px;*/   margin-bottom: 5px }
.ztree li a.curSelectedNode {color:#2C9AEF; padding:1px 3px 0 3px;background-color: #F9F9F9; border: none;opacity: 1; }

/*.ztree li a.curSelectedNode {padding-top:0px; background-color:#FFE6B0; color:black; height:16px; border:1px #FFB951 solid; opacity:0.8;}*/
.ztree li a.curSelectedNode_Edit {padding-top:0px; background-color:#FFE6B0;  color:black; height:16px; border:1px #FFB951 solid; opacity:0.8;}
.ztree li a.tmpTargetNode_inner {padding-top:0px; background-color:#316AC5; color:white; height:16px; border:1px #316AC5 solid;
	opacity:0.8; filter:alpha(opacity=80)}
.ztree li a.tmpTargetNode_prev {}
.ztree li a.tmpTargetNode_next {}
.ztree li a input.rename {height:14px; width:80px; padding:0; margin:0;
	font-size:13px; border:1px #7EC4CC solid; *border:0px}
.ztree li span {/*line-height:16px;*/ margin-right:2px; margin-bottom: 26px;}
.ztree li span.button {line-height:0; margin:0; width:16px; height:16px; display: inline-block; vertical-align:middle;
	border:0 none; cursor: pointer;outline:none;
	background-color:transparent; background-repeat:no-repeat; background-attachment: scroll;
	background-image:url("./img/zTreeStandard.png"); *background-image:url("./img/zTreeStandard.gif")}

.ztree li span.button.chk {width:13px; height:13px; /*margin:0 3px 0 0;*/ margin: 0 6px 6px 3px; cursor: auto}
.ztree li span.button.chk.checkbox_false_full {background-position:0 0}
.ztree li span.button.chk.checkbox_false_full_focus {background-position:0 -14px}
.ztree li span.button.chk.checkbox_false_part {background-position:0 -28px}
.ztree li span.button.chk.checkbox_false_part_focus {background-position:0 -42px}
.ztree li span.button.chk.checkbox_false_disable {background-position:0 -56px}
.ztree li span.button.chk.checkbox_true_full {background-position:-14px 0}
.ztree li span.button.chk.checkbox_true_full_focus {background-position:-14px -14px}
.ztree li span.button.chk.checkbox_true_part {background-position:-14px -28px}
.ztree li span.button.chk.checkbox_true_part_focus {background-position:-14px -42px}
.ztree li span.button.chk.checkbox_true_disable {background-position:-14px -56px}
.ztree li span.button.chk.radio_false_full {background-position:-28px 0}
.ztree li span.button.chk.radio_false_full_focus {background-position:-28px -14px}
.ztree li span.button.chk.radio_false_part {background-position:-28px -28px}
.ztree li span.button.chk.radio_false_part_focus {background-position:-28px -42px}
.ztree li span.button.chk.radio_false_disable {background-position:-28px -56px}
.ztree li span.button.chk.radio_true_full {background-position:-42px 0}
.ztree li span.button.chk.radio_true_full_focus {background-position:-42px -14px}
.ztree li span.button.chk.radio_true_part {background-position:-42px -28px}
.ztree li span.button.chk.radio_true_part_focus {background-position:-42px -42px}
.ztree li span.button.chk.radio_true_disable {background-position:-42px -56px}

.ztree li span.button.switch {width:18px; height:18px}
.ztree li span.button.root_open{background-position:-92px -54px}
.ztree li span.button.root_close{background-position:-74px -54px}
.ztree li span.button.roots_open{background-position:-92px 0}
.ztree li span.button.roots_close{background-position:-74px 0}
.ztree li span.button.center_open{background-position:-92px -18px}
.ztree li span.button.center_close{background-position:-74px -18px}
.ztree li span.button.bottom_open{background-position:-92px -36px}
.ztree li span.button.bottom_close{background-position:-74px -36px}
.ztree li span.button.noline_open{background-position:-92px -72px}
.ztree li span.button.noline_close{background-position:-74px -72px}
.ztree li span.button.root_docu{ background:none;}
.ztree li span.button.roots_docu{background-position:-56px 0}
.ztree li span.button.center_docu{background-position:-56px -18px}
.ztree li span.button.bottom_docu{background-position:-56px -36px}
.ztree li span.button.noline_docu{ background:none;}

/*
.ztree li span.button.ico_open{margin-right:2px; background-position:-110px -16px; vertical-align:top; *vertical-align:middle}
.ztree li span.button.ico_close{margin-right:2px; background-position:-110px 0; vertical-align:top; *vertical-align:middle}
.ztree li span.button.ico_docu{margin-right:2px; background-position:-110px -32px; vertical-align:top; *vertical-align:middle}
*/
.ztree li span.button.ico_open{
	width: 16px;
    height: 16px;
    margin-right:2px;
    display: inline-block;
    background: url(img/folder_open.png) no-repeat;
	vertical-align:middle;
	*vertical-align:middle;
	display: none;
}
.ztree li span.button.ico_close{
	width: 16px;
    height: 16px;
    margin-right:2px;
    display: inline-block;
    background: url(img/folder.png) no-repeat;
	vertical-align:middle;
	*vertical-align:middle;
	display: none;
}
.ztree li span.button.ico_docu{
	width: 16px;
    height:16px;
    margin-right:2px;
    display: inline-block;
    background: url(img/leaf.png) no-repeat;
	vertical-align:middle;
	*vertical-align:middle
}

.ztree li span.button.edit {margin-right:2px; background-position:-110px -48px; vertical-align:top; *vertical-align:middle}
.ztree li span.button.remove {margin-right:2px; background-position:-110px -64px; vertical-align:top; *vertical-align:middle}

.ztree li span.button.ico_loading{margin-right:2px; background:url(./img/loading.gif) no-repeat scroll 0 0 transparent; vertical-align:top; *vertical-align:middle}

ul.tmpTargetzTree {background-color:#FFE6B0; opacity:0.8; filter:alpha(opacity=80)}

span.tmpzTreeMove_arrow {width:16px; height:16px; display: inline-block; padding:0; margin:2px 0 0 1px; border:0 none; position:absolute;
	background-color:transparent; background-repeat:no-repeat; background-attachment: scroll;
	background-position:-110px -80px; background-image:url("./img/zTreeStandard.png"); *background-image:url("./img/zTreeStandard.gif")}

ul.ztree.zTreeDragUL {margin:0; padding:0; position:absolute; width:auto; height:auto;overflow:hidden; background-color:#cfcfcf; border:1px #00B83F dotted; opacity:0.8; filter:alpha(opacity=80)}
.zTreeMask {z-index:10000; background-color:#cfcfcf; opacity:0.0; filter:alpha(opacity=0); position:absolute}

/* level style*/
/*.ztree li span.button.level0 {
	display:none;
}
.ztree li ul.level0 {
	padding:0;
	background:none;
}*/


text:
package jp.gr.java_conf.genzo.java.sample.gson;

import java.io.InputStreamReader;
import java.lang.reflect.Type;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.JsonDeserializationContext;
import com.google.gson.JsonDeserializer;
import com.google.gson.JsonElement;
import com.google.gson.JsonParseException;
import com.google.gson.reflect.TypeToken;

public class GsonEnum {

	public static void main(String[] args) {
		Gson gson = new Gson();

		// タイプを取り出す(List)
		Type type = new TypeToken<List<Signal>>() {}.getType();

		// JSON->List<Signal>
		List<Signal> signal = gson.fromJson(new InputStreamReader(
				GsonMap.class.getResourceAsStream("signal2.json")), type);

		System.out.println("---step1---");
		System.out.println(signal);

		// JSON->List<Signal>
		// #1 TypeAdapterを設定したGsonを生成する
		Gson gson2 = new GsonBuilder().registerTypeAdapter(SignalStat.class,
				new SignalStatDeserializer()).create();
		List<Signal> signal2 = gson2.fromJson(new InputStreamReader(
				GsonMap.class.getResourceAsStream("signal3.json")), type);

		System.out.println("---step2---");
		System.out.println(signal2);
	}

	/**
	 * 解析結果を受け取るクラス
	 */
	static class Signal {
		private SignalStat stat;
		private String message;
		private SignalStat next;

		@Override
		public String toString() {
			StringBuffer sb = new StringBuffer();
			sb.append("[");
			sb.append("stat=").append(stat);
			sb.append(" message=").append(message);
			sb.append(" next=").append(next);
			sb.append("]");

			return new String(sb);
		}
	}

	/**
	 * ステータスの表現.
	 */
	enum SignalStat {
		Red, Yellow, Blue;

		// #2 変換用のMAP(int -> SignalStat)
		static Map<Integer, SignalStat> CONVERTER = new HashMap<Integer, SignalStat>();
		static {
			for (SignalStat stat : SignalStat.values()) {
				CONVERTER.put(stat.ordinal(), stat);
			}
		}
	}

	/**
	 * SignalStat用Deserializer.
	 */
	static private class SignalStatDeserializer implements
			JsonDeserializer<SignalStat> {

		@Override
		public SignalStat deserialize(JsonElement json, Type typeOfT,
				JsonDeserializationContext context) throws JsonParseException {
			// #3 int -> SignalStat
			return SignalStat.CONVERTER.get(json.getAsInt());
		}
	}
}


text:
var peg = require("pegjs");
var gen = require("escodegen");
var fs = require("fs");
var vm = require("vm");

var helpers = fs.readFileSync("helpers.js").toString();
var lang = fs.readFileSync("lua.pegjs").toString();
var parser = peg.buildParser(helpers + lang);

var AST;
try {
    AST = parser.parse(fs.readFileSync(process.argv[2]).toString(), {forceVar: true, decorateLuaObjects: true, luaCalls: true, luaOperators: true });
} catch ( e ) {
    console.dir(e);
    return;
}

var src = "(function() " + gen.generate(AST) + "())";

console.log(src);

vm.runInNewContext(src, require('./public/stdlib.js'), "vm");


text:
/**
 * The HTTP4S File Provider.
 */
package org.apache.commons.vfs2.provider.http4s;


text:
@class MISSING_TYPE, NSPopUpButton;

@interface _TtC15DVTSourceEditor44DVTSourceEditorPrintPanelAccessoryController : NSViewController <NSPrintPanelAccessorizing>
{
    MISSING_TYPE *fontAndColorThemePopupButton;
    MISSING_TYPE *printView;
    MISSING_TYPE *selectedFontAndColorTheme;
}

- (void).cxx_destruct;
- (id)initWithCoder:(id)arg1;
- (id)initWithNibName:(id)arg1 bundle:(id)arg2;
- (void)didSelectTheme:(id)arg1;
- (void)viewDidLoad;
- (id)keyPathsForValuesAffectingPreview;
- (id)localizedSummaryItems;
@property(nonatomic, retain) NSPopUpButton *fontAndColorThemePopupButton; // @synthesize fontAndColorThemePopupButton;

@end


text:
Python Monte Carlo Efficient Frontier (PyMCEF) package
======================================================

Purpose
=======
PyMCEF is a python package that can generate efficient frontier based on Monte Carlo simulated returns.

`A Quickstart tutorial`_

`Benchmark`_

PyMCEF is based on axiomatic Second-order Stochastic dominance portfolio theory.

Absolute SemiDeviation and Fixed-target expected under performance are used as the risk measure for
this stochastic programming problem.
These two risk measures don't have the theoretical flaw in mean variance model.

`One example when mean variance model fails`_

User input
==========
The Monte Carlo simulated returns for all the assets in the investment universe is the input
and will be to used to train the efficient frontier.

(Optional) The returns as a validation set to measure the performance of the efficient frontier.

Computation results
===================
The complete efficient frontier stored as a vector of efficient portfolios,
each of which containing the following:

    1. A python dictionary, storing the asset index and weight in the portfolio
    2. In sample performance (Sharpe ratio etc.)
    3. The lower and upper bound for the risk tolerance producing this particular portfolio
    4. Validation performance, if validation Monte Carlo simulated returns are provided.

Advantage
=========

This package implements the algorithm introduced by Prof. Robert J. Vanderbei in his Book:
`Linear Programming: Foundations and Extensions`_ and paper `Frontiers of Stochastically Nondominated Portfolios`_

This algorithm is very efficient, starting with risk tolerance (lagrangian multiplier) being infinite and the optimal
portfolio being 100% in the asset with the largest average return, only portfolios on the efficient
frontier will be visited. With the product of number of assets and number of simulated return less than
10 million, the time needed to construct the full efficient frontier is less than 1 minute.

Speed comparison on efficient frontier construction with other LP solvers
=========================================================================

.. image:: https://github.com/hzzyyy/pymcef/blob/master/output/performance.png

This algorithm is based on simulated returns so it is model agnostic
====================================================================

This introduce huge flexibility to the user as no assumption is made on the type of return distribution (e.g. Gaussian).

.. _`Linear Programming: Foundations and Extensions`: http://www.princeton.edu/~rvdb/LPbook/
.. _`Frontiers of Stochastically Nondominated Portfolios`: http://www.princeton.edu/~rvdb/tex/lpport/lpport8.pdf
.. _`A Quickstart tutorial`: http://nbviewer.jupyter.org/github/hzzyyy/pymcef/blob/master/Quickstart%20tutorial.ipynb
.. _`Benchmark`: http://nbviewer.jupyter.org/github/hzzyyy/pymcef/blob/master/Benchmark.ipynb
.. _`One example when mean variance model fails`: http://nbviewer.jupyter.org/github/hzzyyy/pymcef/blob/master/examples/1.%20When%20mean%20variance%20models%20fail.ipynb


text:
<!DOCTYPE html>

   <link href="css/slides.css" rel="stylesheet" />

Start
Prev
Next

5. Working with Agents

create_agent concerns

If the API docs for models/schema are not available look at the
web UI for agents.  The required fields will in the form will be
the ones we want to handle. Sometimes you may have to experiment
and guess.

The API validates the requests. The response case from the API
will often hint at what we’re missing.  curl can be a real help
here as the error response in JSON wil give us clues to what is
missing. Sometimes that is not as visible from the Python shell.

Relying on the API validation does allow us to simplify our client
code but we need to do more in our tests sorting out the right
structure to send.


text:
delay_shield
============

This PHP library periodically delays HTTP requests using a special cookie and responses a count back interface during delay time.
It is an ideal solution for shareware or demo subscriptions. You can notify you users it is demo. You force to read the message until the delay time ended.
After it they can use the web application until the open session is not expired.

## Install

Go to install derectory. And clone the repostitory. If you want to use it in more php application (eg. virtual host environment) you should install it to /usr/share/php/ path.

```bash
cd /usr/share/php
git clone https://github.com/maximalink/delay_shield
```

## Usage

On your file that you want to protect. (eg. the most common is index.php)

```php
<?php
// ... your code is here, that bootstrap your application
// ... delay_shield settings (see Configuration).
$is_open = include('delay_shield/delay_shield.php');
// use $is_open boolean variable to decide if the server
// keep on responding. At this point the count back page is printed out.
// ... and more code is here, that would generate
// the main content that you want to protect
?>
```

## Configuration

All the settings must be defined before the include the delay_shield.php file.

### DELAY_SHIELD_SECRET_KEY

You should define a DELAY_SHIELD_SECRET_KEY constant. It should be a string that contains random characters. The more complex string, the better.
This constant is mandatory.

```php
define('DELAY_SHIELD_SECRET_KEY', 'VeRyComPlEX5ECR3Tk3y....#####$$$$%%%%....');
```

### DELAY_SHIELD_DELAY_IN_SECONDS

Optional integer constant. It defines the time in seconds your user have to wait for the real content.
Default value: 20

```php
define('DELAY_SHIELD_DELAY_IN_SECONDS', 20);
```

### DELAY_SHIELD_OPEN_IN_SECONDS

Optional integer constant. It defines the time in seconds your user can browse without any delay. Every open session opens after after a delay session.
Default value: 120

```php
define('DELAY_SHIELD_OPEN_IN_SECONDS', 120);
```

### DELAY_SHIELD_BRAND_LEFT

Optional string constant. It defines the brand that show on the left of navbar.
It has no default value.

```php
define('DELAY_SHIELD_BRAND_LEFT', 'MyCompany');
```

### DELAY_SHIELD_BRAND_RIGHT

Optional string constant. It defines the brand that show on the left of navbar.
It has no default value.

```php
define('DELAY_SHIELD_BRAND_LEFT', 'MyWebApp');
```

### DELAY_SHIELD_MESSAGE

Optional but recommended string constant. It defines the message that shows up on counter page.
Default value: 'You have been delayed. See the counter and click the button.'

```php
define('DELAY_SHIELD_MESSAGE', 'Your credit card has been expired. Please renew it as soon as possible.');
```

### DELAY_SHIELD_CLOSE_BUTTON

Optional string constant. It defines the label of close button.
Default value: 'Close and continue >>'

```php
define('DELAY_SHIELD_CLOSE_BUTTON', 'Close the message');
```


text:
from JumpScale9 import j
from .ExecutorBase import ExecutorBase
import subprocess
import os
import pytoml
import socket
import sys

JSBASE = j.application.jsbase_get_class()

class ExecutorLocal(ExecutorBase):

    def __init__(self, debug=False, checkok=False):
        if not hasattr(self, '__jslocation__'):
            self.__jslocation__ = "j.tools.executorLocal"
        self._cache_expiration = 3600
        ExecutorBase.__init__(self, debug=debug, checkok=debug)
        self.type = "local"
        self._id = 'localhost'
        self._logger = self.logger

        # self.cache = j.data.cache.get(id="executor:%s" % self.id,expiration=3600)

    def exists(self, path):
        return j.sal.fs.exists(path)

    @property
    def stateOnSystem(self):
        """
        is dict of all relevant param's on system
        """

        def getenv():
            res = {}
            for key, val in os.environ.items():
                res[key] = val
            return res

        def do():
            # print ("INFO: stateonsystem for local")

            if "HOMEDIR" in os.environ.keys():
                homedir = os.environ["HOMEDIR"]
            else:
                # if os.path.exists("/root/.iscontainer"):
                #     homedir = "/host"
                # else:
                homedir = os.environ["HOME"]
            cfgdir = "%s/js9host/cfg" % homedir
            res = {}

            def load(name):
                path = "%s/%s.toml" % (cfgdir, name)
                if os.path.exists(path):
                    return pytoml.loads(j.sal.fs.fileGetContents(path))
                else:
                    return {}

            res["cfg_js9"] = load("jumpscale9")
            res["cfg_state"] = load("state")
            res["cfg_me"] = load("me")
            res["env"] = getenv()

            # res["uname"] = subprocess.Popen("uname -mnprs", stdout=subprocess.PIPE,
            #                                 shell=True).stdout.read().decode().strip()
            # res["hostname"] = subprocess.Popen("hostname", stdout=subprocess.PIPE,
            #                                    shell=True).stdout.read().decode().strip()
            res["uname"] = None
            res["hostname"] = socket.gethostname()

            if "darwin" in sys.platform.lower():
                res["os_type"] = "darwin"
            elif "linux" in sys.platform.lower():
                res["os_type"] = "ubuntu"  # dirty hack, will need to do something better, but keep fast
            else:
                print("need to fix for other types (check executorlocal")
                sys.exit(1)

            path = path = "%s/.profile_js" % (homedir)
            if os.path.exists(path):
                res["bashprofile"] = j.sal.fs.fileGetContents(path)
            else:
                res["bashprofile"] = ""

            res["path_jscfg"] = cfgdir

            if os.path.exists("/root/.iscontainer"):
                res["iscontainer"] = True
            else:
                res["iscontainer"] = False

            return res

        if self._stateOnSystem == None:
            self._stateOnSystem = do()  # don't use cache

        return self._stateOnSystem

    def executeRaw(self, cmd, die=True, showout=False):
        return self.execute(cmd, die=die, showout=showout)

    def execute(self, cmds, die=True, checkok=None, showout=False, timeout=1000, env={}, sudo=False):
        """
        @RETURN rc, out, err
        """
        if env:
            self.env.update(env)
        # if self.debug:
        #     print("EXECUTOR:%s" % cmds)

        if checkok is None:
            checkok = self.checkok

        cmds2 = self.commands_transform(cmds, die=die, checkok=checkok, env=env, sudo=sudo)

        rc, out, err = j.sal.process.execute(cmds2, die=die, showout=showout, timeout=timeout)

        if checkok:
            out = self._docheckok(cmds, out)

        return rc, out, err

    def executeInteractive(self, cmds, die=True, checkok=None):
        cmds = self.commands_transform(cmds, die, checkok=checkok)
        return j.sal.process.executeWithoutPipe(cmds)

    def upload(self, source, dest, dest_prefix="", recursive=True):
        if dest_prefix != "":
            dest = j.sal.fs.joinPaths(dest_prefix, dest)
        if j.sal.fs.isDir(source):
            j.sal.fs.copyDirTree(
                source,
                dest,
                keepsymlinks=True,
                deletefirst=False,
                overwriteFiles=True,
                ignoredir=[
                    ".egg-info",
                    ".dist-info"],
                ignorefiles=[".egg-info"],
                rsync=True,
                ssh=False,
                recursive=recursive)
        else:
            j.sal.fs.copyFile(source, dest, overwriteFile=True)
        self.cache.reset()

    def download(self, source, dest, source_prefix=""):
        if source_prefix != "":
            source = j.sal.fs.joinPaths(source_prefix, source)

        if j.sal.fs.isFile(source):
            j.sal.fs.copyFile(source, dest)
        else:
            j.sal.fs.copyDirTree(
                source,
                dest,
                keepsymlinks=True,
                deletefirst=False,
                overwriteFiles=True,
                ignoredir=[
                    ".egg-info",
                    ".dist-info"],
                ignorefiles=[".egg-info"],
                rsync=True,
                ssh=False)

    def file_read(self, path):
        return j.sal.fs.readFile(path)

    def file_write(self, path, content, mode=None, owner=None, group=None, append=False, sudo=False):
        j.sal.fs.createDir(j.sal.fs.getDirName(path))
        j.sal.fs.writeFile(path, content, append=append)
        if owner is not None or group is not None:
            j.sal.fs.chown(path, owner, group)
        if mode != None:
            j.sal.fs.chmod(path, mode)


text:
set -o errexit -o nounset

# Store repository root dir
repo_dir=$(pwd)

cd ~
git clone https://github.com/zeromq/cppzmq.git
mkdir -p build_cppzmq
cd build_cppzmq
cmake ../cppzmq -DCMAKE_MODULE_PATH=$repo_dir/src/cmake/Modules
make
make install

cd $repo_dir


text:
package org.apache.phoenix.trace;

import java.sql.Array;
import java.sql.Blob;
import java.sql.CallableStatement;
import java.sql.Clob;
import java.sql.Connection;
import java.sql.DatabaseMetaData;
import java.sql.NClob;
import java.sql.PreparedStatement;
import java.sql.SQLClientInfoException;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.SQLXML;
import java.sql.Savepoint;
import java.sql.Statement;
import java.sql.Struct;
import java.util.Map;
import java.util.Properties;
import java.util.concurrent.Executor;

/**
 * Simple {@link Connection} that just delegates to an underlying {@link Connection}.
 */
public class DelegateConnection implements Connection {

  @Override
  public <T> T unwrap(Class<T> iface) throws SQLException {
    return conn.unwrap(iface);
  }

  @Override
  public boolean isWrapperFor(Class<?> iface) throws SQLException {
    return conn.isWrapperFor(iface);
  }

  @Override
  public Statement createStatement() throws SQLException {
    return conn.createStatement();
  }

  @Override
  public PreparedStatement prepareStatement(String sql) throws SQLException {
    return conn.prepareStatement(sql);
  }

  @Override
  public CallableStatement prepareCall(String sql) throws SQLException {
    return conn.prepareCall(sql);
  }

  @Override
  public String nativeSQL(String sql) throws SQLException {
    return conn.nativeSQL(sql);
  }

  @Override
  public void setAutoCommit(boolean autoCommit) throws SQLException {
    conn.setAutoCommit(autoCommit);
  }

  @Override
  public boolean getAutoCommit() throws SQLException {
    return conn.getAutoCommit();
  }

  @Override
  public void commit() throws SQLException {
    conn.commit();
  }

  @Override
  public void rollback() throws SQLException {
    conn.rollback();
  }

  @Override
  public void close() throws SQLException {
    conn.close();
  }

  @Override
  public boolean isClosed() throws SQLException {
    return conn.isClosed();
  }

  @Override
  public DatabaseMetaData getMetaData() throws SQLException {
    return conn.getMetaData();
  }

  @Override
  public void setReadOnly(boolean readOnly) throws SQLException {
    conn.setReadOnly(readOnly);
  }

  @Override
  public boolean isReadOnly() throws SQLException {
    return conn.isReadOnly();
  }

  @Override
  public void setCatalog(String catalog) throws SQLException {
    conn.setCatalog(catalog);
  }

  @Override
  public String getCatalog() throws SQLException {
    return conn.getCatalog();
  }

  @Override
  public void setTransactionIsolation(int level) throws SQLException {
    conn.setTransactionIsolation(level);
  }

  @Override
  public int getTransactionIsolation() throws SQLException {
    return conn.getTransactionIsolation();
  }

  @Override
  public SQLWarning getWarnings() throws SQLException {
    return conn.getWarnings();
  }

  @Override
  public void clearWarnings() throws SQLException {
    conn.clearWarnings();
  }

  @Override
  public Statement createStatement(int resultSetType, int resultSetConcurrency) throws SQLException {
    return conn.createStatement(resultSetType, resultSetConcurrency);
  }

  @Override
  public PreparedStatement
      prepareStatement(String sql, int resultSetType, int resultSetConcurrency) throws SQLException {
    return conn.prepareStatement(sql, resultSetType, resultSetConcurrency);
  }

  @Override
  public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency)
      throws SQLException {
    return conn.prepareCall(sql, resultSetType, resultSetConcurrency);
  }

  @Override
  public Map<String, Class<?>> getTypeMap() throws SQLException {
    return conn.getTypeMap();
  }

  @Override
  public void setTypeMap(Map<String, Class<?>> map) throws SQLException {
    conn.setTypeMap(map);
  }

  @Override
  public void setHoldability(int holdability) throws SQLException {
    conn.setHoldability(holdability);
  }

  @Override
  public int getHoldability() throws SQLException {
    return conn.getHoldability();
  }

  @Override
  public Savepoint setSavepoint() throws SQLException {
    return conn.setSavepoint();
  }

  @Override
  public Savepoint setSavepoint(String name) throws SQLException {
    return conn.setSavepoint(name);
  }

  @Override
  public void rollback(Savepoint savepoint) throws SQLException {
    conn.rollback(savepoint);
  }

  @Override
  public void releaseSavepoint(Savepoint savepoint) throws SQLException {
    conn.releaseSavepoint(savepoint);
  }

  @Override
  public Statement createStatement(int resultSetType, int resultSetConcurrency,
      int resultSetHoldability) throws SQLException {
    return conn.createStatement(resultSetType, resultSetConcurrency, resultSetHoldability);
  }

  @Override
  public PreparedStatement prepareStatement(String sql, int resultSetType,
      int resultSetConcurrency, int resultSetHoldability) throws SQLException {
    return conn.prepareStatement(sql, resultSetType, resultSetConcurrency, resultSetHoldability);
  }

  @Override
  public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency,
      int resultSetHoldability) throws SQLException {
    return conn.prepareCall(sql, resultSetType, resultSetConcurrency, resultSetHoldability);
  }

  @Override
  public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys) throws SQLException {
    return conn.prepareStatement(sql, autoGeneratedKeys);
  }

  @Override
  public PreparedStatement prepareStatement(String sql, int[] columnIndexes) throws SQLException {
    return conn.prepareStatement(sql, columnIndexes);
  }

  @Override
  public PreparedStatement prepareStatement(String sql, String[] columnNames) throws SQLException {
    return conn.prepareStatement(sql, columnNames);
  }

  @Override
  public Clob createClob() throws SQLException {
    return conn.createClob();
  }

  @Override
  public Blob createBlob() throws SQLException {
    return conn.createBlob();
  }

  @Override
  public NClob createNClob() throws SQLException {
    return conn.createNClob();
  }

  @Override
  public SQLXML createSQLXML() throws SQLException {
    return conn.createSQLXML();
  }

  @Override
  public boolean isValid(int timeout) throws SQLException {
    return conn.isValid(timeout);
  }

  @Override
  public void setClientInfo(String name, String value) throws SQLClientInfoException {
    conn.setClientInfo(name, value);
  }

  @Override
  public void setClientInfo(Properties properties) throws SQLClientInfoException {
    conn.setClientInfo(properties);
  }

  @Override
  public String getClientInfo(String name) throws SQLException {
    return conn.getClientInfo(name);
  }

  @Override
  public Properties getClientInfo() throws SQLException {
    return conn.getClientInfo();
  }

  @Override
  public Array createArrayOf(String typeName, Object[] elements) throws SQLException {
    return conn.createArrayOf(typeName, elements);
  }

  @Override
  public Struct createStruct(String typeName, Object[] attributes) throws SQLException {
    return conn.createStruct(typeName, attributes);
  }

    private Connection conn;

    public DelegateConnection(Connection conn) {
    this.conn = conn;
  }

    @Override
    public void setSchema(String schema) throws SQLException {
        conn.setSchema(schema);
    }

    @Override
    public String getSchema() throws SQLException {
        return conn.getSchema();
    }

    @Override
    public void abort(Executor executor) throws SQLException {
        conn.abort(executor);
    }

    @Override
    public void setNetworkTimeout(Executor executor, int milliseconds) throws SQLException {
        conn.setNetworkTimeout(executor, milliseconds);
    }

    @Override
    public int getNetworkTimeout() throws SQLException {
        return conn.getNetworkTimeout();
    }
}


text:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

  <title>Examples : Delayed Job Admin</title>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
  <link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/combo?3.0.0b1/build/cssfonts/fonts-min.css&3.0.0b1/build/cssreset/reset-min.css&3.0.0b1/build/cssbase/base-min.css">
  <link href="../public/stylesheets/delayed_job_admin.css" media="all" rel="stylesheet" type="text/css" />

Examples R Us Administration

Dashboard

Delayed Jobs

Secret Data

              15
              failed

              3
              locked

              20
              total

          27 Aug 09:36
          ErrorJob fan_id: 187

            <a href="/delayed_jobs/50" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

          Locked by host:example-host.local pid:59093
          on August 27, 2009 09:36

           1st
            attempt failed August 27, 2009 09:36

ActiveRecord::RecordNotFound: Could not find Fan with id of '12345'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):41:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:36
            last updated August 27, 2009 09:36

           27 Aug 09:36
          ErrorJob fan_id: 321

            <a href="/delayed_jobs/48" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

          Locked by host:example-host.local pid:59093
          on August 27, 2009 09:36

           1st
            attempt failed August 27, 2009 09:36

ActiveRecord::RecordNotFound: Could not find Fan with id of '12345'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):41:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:36
            last updated August 27, 2009 09:36

           27 Aug 09:32
          ErrorJob message_id 9823

            <a href="/delayed_jobs/36" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Fan with id of '12345'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:29
            last updated August 27, 2009 09:31

          27 Aug 09:36
          ErrorJob fan_id 189323

            <a href="/delayed_jobs/49" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

          Locked by host:example-host.local pid:59093
          on August 27, 2009 09:36

           1st
            attempt failed August 27, 2009 09:36

ArgumentError: Too many arguments (3 for 2)
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):41:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:36
            last updated August 27, 2009 09:36

          27 Aug 09:37
          ErrorJob fan_id 35184

            <a href="/delayed_jobs/51" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

            Created August 27, 2009 09:37
            last updated August 27, 2009 09:37

          27 Aug 09:32
          ErrorJob message_id 923

            <a href="/delayed_jobs/39" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ArgumentError: Too many arguments (3 for 2)
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:37
          ErrorJob message_id 1278

            <a href="/delayed_jobs/52" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

            Created August 27, 2009 09:37
            last updated August 27, 2009 09:37

          27 Aug 09:37
          ErrorJob message_id 54

            <a href="/delayed_jobs/53" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

            Created August 27, 2009 09:37
            last updated August 27, 2009 09:37

          27 Aug 09:37
          ErrorJob message_id 9832

            <a href="/delayed_jobs/54" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

            Created August 27, 2009 09:37
            last updated August 27, 2009 09:37

          27 Aug 09:37
          ErrorJob message_id 9832

            <a href="/delayed_jobs/55" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

            Created August 27, 2009 09:37
            last updated August 27, 2009 09:37

          27 Aug 09:32
          ErrorJob message_id 5413

            <a href="/delayed_jobs/41" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ArgumentError: Too many arguments (3 for 2)
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob message_id 7621

            <a href="/delayed_jobs/38" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob message_id 5821

            <a href="/delayed_jobs/40" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob message_id 1983

            <a href="/delayed_jobs/44" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 2389

            <a href="/delayed_jobs/43" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 58103

            <a href="/delayed_jobs/45" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 5416

            <a href="/delayed_jobs/42" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 4544

            <a href="/delayed_jobs/37" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 8932

            <a href="/delayed_jobs/47" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31

          27 Aug 09:32
          ErrorJob fan_id 1264

            <a href="/delayed_jobs/46" class="dangerous" onclick="var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = this.href;var m = document.createElement('input'); m.setAttribute('type', 'hidden'); m.setAttribute('name', '_method'); m.setAttribute('value', 'delete'); f.appendChild(m);var s = document.createElement('input'); s.setAttribute('type', 'hidden'); s.setAttribute('name', 'authenticity_token'); s.setAttribute('value', '4ZJ0kSVF//xTAZrMhsuSnZp6fS1MRcO1jds/QkcDsP0='); f.appendChild(s);f.submit();return false;">delete

           1st
            attempt failed August 27, 2009 09:31

ActiveRecord::RecordNotFound: Could not find Message with id of '9385'
      (irb):3:in `perform'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:217:in `invoke_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:92:in `run_with_lock'
      /Library/Ruby/Gems/1.8/gems/activesupport-2.3.2/lib/active_support/core_ext/benchmark.rb:10:in `realtime'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:91:in `run_with_lock'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:155:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `each'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:154:in `reserve_and_run_one_job'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:201:in `work_off'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `times'
      /path/to/example/app/vendor/plugins/delayed_job/lib/delayed/job.rb:200:in `work_off'
      (irb):28:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52:in `irb_binding'
      /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/irb/workspace.rb:52

            Created August 27, 2009 09:30
            last updated August 27, 2009 09:31


text:
from __future__ import unicode_literals

from django.db import migrations
import draceditor.models

class Migration(migrations.Migration):

    dependencies = [
        ('blog', '0004_auto_20170801_1347'),
    ]

    operations = [
        migrations.AlterField(
            model_name='entry',
            name='body',
            field=draceditor.models.DraceditorField(verbose_name='Contenido'),
        ),
    ]


text:
#include <assert.h>
#include <math.h>

#include "coco.h"
#include "coco_problem.c"
#include "suite_bbob_legacy_code.c"
#include "transform_obj_shift.c"

typedef struct {
  double *x_hat, *z;
  double *xopt, fopt;
  double **rot1, **rot2;
  long rseed;
  coco_free_function_t old_free_problem;
} f_lunacek_bi_rastrigin_data_t;

static double f_lunacek_bi_rastrigin_raw(const double *x,
                                         const size_t number_of_variables,
                                         f_lunacek_bi_rastrigin_data_t *data) {
  double result;
  static const double condition = 100.;
  size_t i, j;
  double penalty = 0.0;
  static const double mu0 = 2.5;
  static const double d = 1.;
  const double s = 1. - 0.5 / (sqrt((double) (number_of_variables + 20)) - 4.1);
  const double mu1 = -sqrt((mu0 * mu0 - d) / s);
  double *tmpvect, sum1 = 0., sum2 = 0., sum3 = 0.;

  assert(number_of_variables > 1);

  for (i = 0; i < number_of_variables; ++i) {
    double tmp;
    tmp = fabs(x[i]) - 5.0;
    if (tmp > 0.0)
      penalty += tmp * tmp;
  }

  /* x_hat */
  for (i = 0; i < number_of_variables; ++i) {
    data->x_hat[i] = 2. * x[i];
    if (data->xopt[i] < 0.) {
      data->x_hat[i] *= -1.;
    }
  }

  tmpvect = coco_allocate_vector(number_of_variables);
  /* affine transformation */
  for (i = 0; i < number_of_variables; ++i) {
    double c1;
    tmpvect[i] = 0.0;
    c1 = pow(sqrt(condition), ((double) i) / (double) (number_of_variables - 1));
    for (j = 0; j < number_of_variables; ++j) {
      tmpvect[i] += c1 * data->rot2[i][j] * (data->x_hat[j] - mu0);
    }
  }
  for (i = 0; i < number_of_variables; ++i) {
    data->z[i] = 0;
    for (j = 0; j < number_of_variables; ++j) {
      data->z[i] += data->rot1[i][j] * tmpvect[j];
    }
  }
  /* Computation core */
  for (i = 0; i < number_of_variables; ++i) {
    sum1 += (data->x_hat[i] - mu0) * (data->x_hat[i] - mu0);
    sum2 += (data->x_hat[i] - mu1) * (data->x_hat[i] - mu1);
    sum3 += cos(2 * coco_pi * data->z[i]);
  }
  result = coco_min_double(sum1, d * (double) number_of_variables + s * sum2)
      + 10. * ((double) number_of_variables - sum3) + 1e4 * penalty;
  coco_free_memory(tmpvect);

  return result;
}

static void f_lunacek_bi_rastrigin_evaluate(coco_problem_t *self, const double *x, double *y) {
  assert(self->number_of_objectives == 1);
  y[0] = f_lunacek_bi_rastrigin_raw(x, self->number_of_variables, self->data);
}

static void f_lunacek_bi_rastrigin_free(coco_problem_t *self) {
  f_lunacek_bi_rastrigin_data_t *data;
  data = self->data;
  coco_free_memory(data->x_hat);
  coco_free_memory(data->z);
  coco_free_memory(data->xopt);
  bbob2009_free_matrix(data->rot1, self->number_of_variables);
  bbob2009_free_matrix(data->rot2, self->number_of_variables);

  /* Let the generic free problem code deal with all of the
   * coco_problem_t fields.
   */
  self->free_problem = NULL;
  coco_problem_free(self);
}

/* Note: there is no separate f_lunacek_bi_rastrigin_allocate() function! */

static coco_problem_t *f_lunacek_bi_rastrigin_bbob_problem_allocate(const size_t function,
                                                                    const size_t dimension,
                                                                    const size_t instance,
                                                                    const long rseed,
                                                                    const char *problem_id_template,
                                                                    const char *problem_name_template) {

  f_lunacek_bi_rastrigin_data_t *data;
  coco_problem_t *problem = coco_problem_allocate_from_scalars("Lunacek's bi-Rastrigin function",
      f_lunacek_bi_rastrigin_evaluate, f_lunacek_bi_rastrigin_free, dimension, -5.0, 5.0, 0.0);

  const double mu0 = 2.5;

  double fopt, *tmpvect;
  size_t i;

  data = coco_allocate_memory(sizeof(*data));
  /* Allocate temporary storage and space for the rotation matrices */
  data->x_hat = coco_allocate_vector(dimension);
  data->z = coco_allocate_vector(dimension);
  data->xopt = coco_allocate_vector(dimension);
  data->rot1 = bbob2009_allocate_matrix(dimension, dimension);
  data->rot2 = bbob2009_allocate_matrix(dimension, dimension);
  data->rseed = rseed;

  data->fopt = bbob2009_compute_fopt(24, instance);
  bbob2009_compute_xopt(data->xopt, rseed, dimension);
  bbob2009_compute_rotation(data->rot1, rseed + 1000000, dimension);
  bbob2009_compute_rotation(data->rot2, rseed, dimension);

  problem->data = data;

  /* Compute best solution */
  tmpvect = coco_allocate_vector(dimension);
  bbob2009_gauss(tmpvect, dimension, rseed);
  for (i = 0; i < dimension; ++i) {
    data->xopt[i] = 0.5 * mu0;
    if (tmpvect[i] < 0.0) {
      data->xopt[i] *= -1.0;
    }
    problem->best_parameter[i] = data->xopt[i];
  }
  coco_free_memory(tmpvect);
  f_lunacek_bi_rastrigin_evaluate(problem, problem->best_parameter, problem->best_value);

  fopt = bbob2009_compute_fopt(function, instance);
  problem = f_transform_obj_shift(problem, fopt);

  coco_problem_set_id(problem, problem_id_template, function, instance, dimension);
  coco_problem_set_name(problem, problem_name_template, function, instance, dimension);
  coco_problem_set_type(problem, "5-weakly-structured");

  return problem;
}


text:
<?php $form=$this->beginWidget('bootstrap.widgets.TbActiveForm',array(
	'id'=>'images-form',
	'enableAjaxValidation'=>false,
	'htmlOptions' => array('enctype' => 'multipart/form-data'),
)); ?>

Velden met een * zijn verplicht.

	<?php echo $form->errorSummary($model); ?>

	<?php echo $form->textFieldRow($model,'title',array('class'=>'span5','maxlength'=>64)); ?>

	 <?php echo $form->labelEx($model,'description'); ?>
	 <?php
		 $this->widget('ext.redactor.ImperaviRedactorWidget', array(
		 	'name' => 'Image[description]',
		 	'value' => $model->description,
		 	'options' => array(
		 	'minHeight'=>150,
		 	'class'=>'span8',
		 	'lang'=>'nl',
		 	'buttons'=>array('formatting', '|', 'bold', 'italic', 'deleted', '|', 'unorderedlist', 'orderedlist', 'outdent', 'indent', '|', 'table', 'link', '|', 'horizontalrule')
		 )));
	?>

	<?php
		$tags = '';
		$values = array();
		foreach($model->tags as $i => $tag){
			$tags .= $tag->id.',';
			$values[$i]['id'] = $tag->id;
			$values[$i]['tag'] = $tag->name;
		}
		$tags = substr($tags, 0, -1);
	?>

	<?php
		$this->widget('ext.tagIt.ETagIt', array(
			'id' => 'Image_tags',
		    'url' => $this->createUrl('tag/search'),
		    'options' => array(),
		    'values' => $values,
		));
	?>

	<?php echo $form->hiddenField($model,'tags_previous',array('value'=>$tags)); ?>

	<?php echo $form->textFieldRow($model,'year',array('class'=>'span5')); ?>

	<?php echo $form->textFieldRow($model,'owner',array('class'=>'span5','maxlength'=>45)); ?>

	<?php echo $form->dropDownListRow($model, 'published', array('1'=>'Ja', '0'=>'Nee')); ?>

	<?php
		$this->widget('ext.dropzone.EDropzone', array(
		    'model' => $model,
		    'attribute' => 'file',
		    'url' => $this->createUrl('image/upload'),
		    'mimeTypes' => array('image/jpeg', 'image/png', 'image/gif'),
		    'options' => array(
		    	'dictDefaultMessage' => 'Plaats hier het bestand dat u wilt uploaden',
		    	'dictFallbackMessage' => 'Uw browser wordt niet ondersteund',
		    	'dictInvalidFileType' => 'Dit bestands formaat wordt niet ondersteund. Converteer het a.u.b. naar PDF.',
		    	'dictFileTooBig' => 'Het bestand dat u probeert te uploaden is te groot.',
		    ),
		));
	?>

		<?php $this->widget('bootstrap.widgets.TbButton', array(
			'buttonType'=>'submit',
			'type'=>'primary',
			'label'=>$model->isNewRecord ? 'Maak aan' : 'Bewaar',
		)); ?>

<?php $this->endWidget(); ?>


text:
package net.sf.json.sample;

import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

/**
 * @author Andres Almiray <aalmiray@users.sourceforge.net>
 */
public class ObjectBean {
   private Object parray;
   private Object pbean;
   private Object pboolean;
   private Object pbyte;
   private Object pchar;
   private Object pclass;
   private Object pdouble;
   private Object pexcluded;
   private Object pfloat;
   private Object pfunction;
   private Object pint;
   private Object plist;
   private Object plong;
   private Object pmap;
   private Object pshort;
   private Object pstring;

   public Object getParray() {
      return parray;
   }

   public Object getPbean() {
      return pbean;
   }

   public Object getPboolean() {
      return pboolean;
   }

   public Object getPbyte() {
      return pbyte;
   }

   public Object getPchar() {
      return pchar;
   }

   public Object getPclass() {
      return pclass;
   }

   public Object getPdouble() {
      return pdouble;
   }

   public Object getPexcluded() {
      return pexcluded;
   }

   public Object getPfloat() {
      return pfloat;
   }

   public Object getPfunction() {
      return pfunction;
   }

   public Object getPint() {
      return pint;
   }

   public Object getPlist() {
      return plist;
   }

   public Object getPlong() {
      return plong;
   }

   public Object getPmap() {
      return pmap;
   }

   public Object getPshort() {
      return pshort;
   }

   public Object getPstring() {
      return pstring;
   }

   public void setParray( Object parray ) {
      this.parray = parray;
   }

   public void setPbean( Object bean ) {
      this.pbean = bean;
   }

   public void setPboolean( Object pboolean ) {
      this.pboolean = pboolean;
   }

   public void setPbyte( Object pbyte ) {
      this.pbyte = pbyte;
   }

   public void setPchar( Object pchar ) {
      this.pchar = pchar;
   }

   public void setPclass( Object pclass ) {
      this.pclass = pclass;
   }

   public void setPdouble( Object pdouble ) {
      this.pdouble = pdouble;
   }

   public void setPexcluded( Object pexcluded ) {
      this.pexcluded = pexcluded;
   }

   public void setPfloat( Object pfloat ) {
      this.pfloat = pfloat;
   }

   public void setPfunction( Object pfunction ) {
      this.pfunction = pfunction;
   }

   public void setPint( Object pint ) {
      this.pint = pint;
   }

   public void setPlist( Object plist ) {
      this.plist = plist;
   }

   public void setPlong( Object plong ) {
      this.plong = plong;
   }

   public void setPmap( Object pmap ) {
      this.pmap = pmap;
   }

   public void setPshort( Object pshort ) {
      this.pshort = pshort;
   }

   public void setPstring( Object pstring ) {
      this.pstring = pstring;
   }

   public String toString() {
      return ToStringBuilder.reflectionToString( this, ToStringStyle.MULTI_LINE_STYLE );
   }
}