text:
<?php return array (
  25 => '25',
  'Invalid Password.' => 'Senha inválida.',
  'The user\'s account has been activated and the user has been notified about it.' => 'A conta do usuário foi ativado e que o usuário tenha sido notificado a respeito.',
  'Add Folder' => 'Adicionar Pasta',
  'Rename' => 'Renomear',
  'Removed selected.' => 'Removido selecionado.',
  'Whoops, looks like something went wrong.' => 'Opa, parece que algo deu errado.',
  'Enable' => 'Habilitar',
  'Manage media files' => 'Gerenciar arquivos de Mídia',
  'Update' => 'Atualizar',
  '- Select Type -' => '- Selecionar tipo -',
  'SMTP User' => 'SMTP Usuário',
  'Hide in menu' => 'Esconder no menu',
  'Database Name' => 'Nome do Banco de dados',
  'Last registered' => 'Último registrado',
  'Welcome to %site%!' => 'Bem-vindo ao %site%!',
  'Check Connection' => 'Verifique a conexão',
  'Invalid type.' => 'Tipo inválido.',
  'Path' => 'Caminho',
  'Value' => 'Valor',
  'Invalid url.' => 'Url inválida.',
  'Is your language not available? Please help out by translating Pagekit into your own language on %link%.' => 'Seu idioma não está disponível? Por favor ajude traduzindo o Pagekit para sua linguagem em %link%.',
  'No Limit' => 'Sem Limites',
  'Code' => 'Código',
  'Positions' => 'Posições',
  'Your user account has been created and is pending approval by the site administrator.' => 'Sua conta de usuário foi criada e está pendente de aprovação pelo administrador do site.',
  'Remember Me' => 'Lembrar-me',
  'Info' => 'Informações',
  'Permission' => 'Permissão',
  'Database name cannot be blank.' => 'O nome do Banco de dados não pode estar em branco.',
  7 => '7',
  'System' => 'Sistema',
  'Unable to remove.' => 'Não e possível remover',
  'Latest registered Users' => 'Últimos Usuários registrados',
  'Approve an account at %site%.' => 'Aprove uma conta no %site%.',
  'Developer' => 'Desenvolvedor',
  'Invalid path.' => 'Caminho invalido.',
  'Cannot connect to the server. Please try again later.' => 'Não é possível conectar ao servidor. Por favor, tente novamente mais tarde.',
  'Install' => 'Instalar',
  'Are you sure?' => 'Você tem certeza?',
  'Don\'t show' => 'Não mostrar',
  'Missing order data.' => 'Faltando dados de pedidos.',
  'Warning: Give to trusted roles only; this permission has security implications.' => 'Aviso: Dada a apenas funções de confiança; essa permissão tem implicações de segurança.',
  'Removing package folder.' => 'Removendo diretório do pacote.',
  'Offline' => 'Off-line',
  'Add %type%' => 'Adicionar %type%',
  'User Login' => 'Login de usuário',
  'Activate' => 'Ativar',
  'Next' => 'Próximo',
  'Setup your site' => 'Ajuste seu site',
  'Apply system updates' => 'Aplicar atualizações ao sistema',
  'Extensions' => 'Extensões ',
  'Uploaded file invalid. (%s)' => 'Arquivo enviado Inválido. (%s)',
  'Forgot Password' => 'Esqueceu a Senha',
  'Unable to send verification link.' => 'Não foi possível enviar link de verificação.',
  'Sub Items' => 'Sub Itens',
  'User Registration' => 'Registro de Usuário',
  'TLS' => 'TLS',
  'Invalid key.' => 'Chave inválida.',
  'Role saved' => 'Função salva',
  'Favicon' => 'Favicon',
  'Name cannot be blank.' => 'O nome não poder estar em branco.',
  'Roles' => 'Funções',
  'Connection not established! (%s)' => 'Conexão não estabelecida! (%s)',
  'Database' => 'Base da Dados',
  'Imperial' => 'Imperial',
  'Activate Account' => 'Ativar conta.',
  'Menu' => 'Menu',
  'Message' => 'Mensagem',
  'Add Widget' => 'Adicionar Widget',
  'None' => 'Nada',
  'Visit Site' => 'Visite o site',
  'Testemail' => 'E-mail de teste',
  'URL' => 'URL',
  'Depth' => 'Profundidade',
  'Invalid name.' => 'Nome inválido.',
  'Selected' => 'Selecionado',
  'Thank you for signing up for %site%. Just one more step! Please click the button below to activate your account.' => 'Obrigado por inscrever-se para %site%. Apenas mais um passo! Por favor clique no botão abaixo para ativar sua conta.',
  'Roles saved' => 'Funções salvas',
  'Profile' => 'Perfil',
  'Site Locale' => 'Local do site',
  'User Settings' => 'Ajustes do Usuário',
  '"%title%" enabled.' => '"%title%" ativado.',
  '"%name%" has not been loaded.' => '"%name%" não foi carregado.',
  4 => '4',
  'Type' => 'Tipo',
  'Manage extensions' => 'Gerenciar Extensões',
  'Your account has been activated.' => 'Sua conta foi ativada.',
  'Disable cache' => 'Desabiltiar o cache',
  'Manage user permissions' => 'Gerenciar permissões de usuários',
  'Can\'t load json file from package.' => 'Não é possível carregar arquivo json de pacote.',
  'Manage widgets' => 'Gerenciar Widgets',
  'Hi %name%!' => 'Olá "%name%"!',
  'Menu Title' => 'Título de Menu',
  'Total Users' => 'Total de Usuários',
  'Email address is invalid.' => 'Endereço de Email invalido.',
  '{0} %count% Users|{1} %count% User|]1,Inf[ %count% Users' => '{0} %count% Users|{1} %count% User|]1,Inf[ %count% Users',
  9 => '9',
  'No pages found.' => 'Nenhuma página encontrada.',
  'Hostname' => 'Nome do Host',
  'Get Help' => 'Obter ajuda',
  'Number of Posts' => 'Número de Posts',
  'All' => 'Tudo',
  'Please enable the SQLite database extension.' => 'Por favor ativar a extensão do banco de dados SQLite.',
  'Enabled, but approval is required.' => 'Ativado, mas é solicitado aprovação.',
  'Description' => 'Descrição',
  'Logged in' => 'Logado',
  'Unknown' => 'Desconhecido',
  'You have the latest version of Pagekit. You do not need to update. However, if you want to re-install version %version%, you can download the package and re-install manually.' => 'Você tem a versão mais recente do Pagekit. Você não precisa atualizar. No entanto, se você quiser re-instalar a versão %version%, você pode baixar o pacote e re-instalar manualmente.',
  'Reset' => 'Redefinir',
  'Feed Widget' => 'Widget Feed',
  'Driver' => 'Motorista',
  'A new user signed up for %site% with the username %username%. Please click the button below to approve the account.' => 'Um novo usuário se inscreveu para %site% com o nome de usuário %username%. Por favor clique no botão abaixo para aprovar a conta.',
  'Dashboard' => 'Dashboard',
  'Widget deleted.' => 'Widget deletado.',
  'Access admin area' => 'Acessar área administrativa',
  'New Password' => 'Nova Senha',
  'Unable to rename.' => 'Não e possível renomear.',
  'Change password' => 'Trocar a senha',
  'password' => 'senha',
  'Create Menu' => 'Criar menu',
  'PHP Mailer' => 'Remetente PHP',
  3 => '3',
  'Select Cache to Clear' => 'Selecionar o Cache para limpar',
  'Alt' => 'Alt',
  '(Currently set to: %menu%)' => '(Atualmente definido para: %menu%)',
  'Pages' => 'Páginas',
  '%d TB' => '%d TB',
  'Mail' => 'E-mail',
  'Logout Redirect' => 'Logout Redirecionado',
  'Invalid id.' => 'Id inválida.',
  'Weather Widget' => 'Widget Clima',
  'Upload' => 'Envio',
  'Logout' => 'Sair',
  '- Menu -' => '- Menu -',
  'Storage' => 'Armazenamento',
  '{1} %count% Widget moved|]1,Inf[ %count% Widgets moved' => '{1} %count% Widget movido|]1,Inf[ %count% Widgets movidos',
  'You will be the site administrator.' => 'Você vai ser o administrador do site.',
  'User Logout' => 'Logout de usuário',
  1 => '1',
  'Reset Password' => 'Redefinir senha',
  'Email:' => 'E-mail:',
  'Enable debug mode' => 'Ativar o modo de depuração',
  'Invalid file name.' => 'Nome de arquivo invalido.',
  'Submit' => 'Enviar',
  'Your account has not been activated.' => 'Sua conta não foi ativada.',
  'Hide' => 'Esconder',
  'No theme found.' => 'Nenhum tema encontrado.',
  'Mail delivery failed!' => 'A entrega de correio falhou!',
  'Installing %title% %version%' => 'Instalando %title% %version%',
  'Connection established!' => 'Conexão estabelecida!',
  'Settings' => 'Configurações',
  'Image' => 'Imagem',
  'Publish' => 'Publicar',
  'Request Password' => 'Solicitação de Senha',
  'Slug' => 'Slug',
  'Renamed.' => 'Renomeado.',
  'Url' => 'Url',
  'No Pagekit %type%' => 'Sem Pagekit %type%',
  'Enter Title' => 'Digite um título',
  'Hidden' => 'Oculto',
  'Select Link' => 'Selecione o link',
  'Your user account has been created. Complete your registration, by clicking the link provided in the mail that has been sent to you.' => 'Sua conta de usuário foi criada. Complete o seu registo, clicando no link fornecido no e-mail que foi enviado a você.',
  'Display' => 'Display',
  'Show all' => 'Mostrar todos',
  'Title cannot be blank.' => 'Título não pode estar em branco.',
  'User cannot be blank.' => 'Usuário não pode estar em branco.',
  'Header' => 'Cabeçalho',
  'Verified Email Address' => 'Endereço de Email verificado',
  'Name required.' => 'Nome necessário.',
  'Select Image' => 'Selecionar Imagem',
  'Table Prefix' => 'Prefixo da tabela',
  'Public user registration is disabled.' => 'Registro de usuário público esta desativado.',
  'Node not found.' => 'Node não encontrado.',
  'Send Test Email' => 'Envie um Email de teste',
  'Pagekit Version' => 'Versão do Pagekit',
  'Last login' => 'Último login',
  'Choose language' => 'Escolha a linguagem',
  'We got a request to reset your %site% password for %username%. If you ignore this message, your password won\'t be changed.' => 'Temos um pedido para redefinir sua %site% senha para %username%. se você ignorar essa mensagem, sua senha não poderá ser alterada.',
  'Invalid slug.' => 'Slug invalido.',
  'Setting' => 'Ajustes',
  'No file uploaded.' => 'Nenhum arquivo enviado.',
  'Close' => 'Fechar',
  'This permission has security implications. Give it trusted roles only.' => 'Esta permissão tem implicações de segurança. Dê-lhe confiável apenas papéis.',
  'Latest logged in Users' => 'Últimos Usuários logados',
  'List' => 'Lista',
  'Invalid token. Please try again.' => 'Token inválido. Por favor, tente novamente.',
  'Homepage:' => 'Pagina inicial:',
  'Login Now' => 'Acesse agora',
  'Connect database' => 'Conecte ao Banco de dados',
  'Show on all posts' => 'Mostrar em todos os posts',
  'You may not call this step directly.' => 'Você não pode chamar essa etapa diretamente.',
  'Folder already exists.' => 'Pasta já existe.',
  'Use the site in maintenance mode' => 'Use o site em modo de manutenção',
  'Successfully removed.' => 'Removido com sucesso.',
  'Access' => 'Acesso',
  'View Permissions' => 'Ver Permissões',
  '{0} Registered Users|{1} Registered User|]1,Inf[ Registered Users' => '{0} Usuários registrados|{1} Usuário registrado|]1,Inf[ Usuários registrados',
  'Version %version%' => 'Versão %version%',
  'Client' => 'Cliente',
  'Frontpage' => 'Pagina principal',
  'Field must be a valid email address.' => 'O campo de endereço de e-mail deve ser valido.',
  'Folder Name' => 'Nome da Pasta',
  'Set as frontpage' => 'Definir como página inicial',
  'Enter password.' => 'Digite a senha.',
  'Username cannot be blank.' => 'Nome de usuário não poder estar em branco.',
  'Unassigned' => 'Não atribuído',
  'Password' => 'Senha',
  'Database connection failed!' => 'A conexão com o Banco de dados falhou!',
  'Installed' => 'Instalado',
  'Registered since' => 'Registrado desde',
  'Your account has not been activated or is blocked.' => 'A sua conta não foi ativado ou está bloqueado.',
  'Menu Positions' => 'Posições do menu',
  100 => '100',
  'Logo' => 'Logo',
  'Your account is blocked.' => 'Sua conta está bloqueada.',
  'Thumbnail' => 'Miniatura',
  'Your Pagekit database has been updated successfully.' => 'Seu banco de dados Pagekit foi atualizado com sucesso.',
  'Whoops, something went wrong.' => 'Ops, algo deu errado.',
  'Widgets reordered.' => 'Widgets reordenados.',
  'Password required.' => 'Password required.',
  'Manage themes' => 'Gerenciar Temas',
  'Enable Markdown' => 'Ativar Markdown',
  '%d  MB' => '%d MB',
  'Temporary Files' => 'Arquivos temporarios',
  'Mail delivery failed! (%s)' => 'A entrega de correio falhou! (%s)',
  'Error' => 'Erro',
  'Please enter your email address. You will receive a link to create a new password via email.' => 'Por favor insira seu endereço de e-mail. você vai receber o link para criar uma nova senha via e-mail.',
  40 => '40',
  '%d PB' => '%d PB',
  'Web Server' => 'Servidor de Web',
  'Hello!' => 'Olá!',
  'Link' => 'Link',
  'Restrict Access' => 'Acesso Restrito',
  'Trash' => 'Lixo',
  'Password Confirmation' => 'Confirmação da senha',
  33 => '33',
  'Verified email address' => 'Verificar o endereço de Email',
  'Email is invalid.' => 'E-mail não é válido.',
  'SMTP Mailer' => 'SMTP Remetente',
  'Unit' => 'Unidade',
  'Themes' => 'Temas',
  'Email not available.' => 'E-mail não disponível.',
  '%d  KB' => '%d KB',
  'No account yet?' => 'Nenhuma conta ainda',
  'Enter your website details.' => 'Preencha os detalhes do seu website.',
  'Failed to save roles.' => 'Falha ao salvar funções.',
  'Add Page' => 'Adicionar Página',
  'Host cannot be blank.' => 'Host não pode estar em branco.',
  'Test email!' => 'E-mail de teste!',
  'Duplicate Menu Id.' => 'ID do menu duplicada.',
  'Database error: %error%' => 'Erro no Banco de dados: %error%',
  'SMTP Encryption' => 'SMTP Criptografia',
  '{1} %count% User selected|]1,Inf[ %count% Users selected' => '{1} %count% User selected|]1,Inf[ %count% Usuário selecionado',
  'Site name cannot be blank.' => 'O nome do site não pode estar em branco.',
  'Cache' => 'Cache',
  'Order saved.' => 'Ordem salva.',
  'Download %version%' => 'Carregar %version%',
  'Unwritable' => 'não gravável',
  'Title' => 'Título',
  'User' => 'Usuário',
  'Password cannot be blank.' => 'Senha não pode estar em branco.',
  'Page not found.' => 'Página não encontrada.',
  'Position' => 'Posição',
  'Start Level' => 'Nivel inicial',
  'SMTP Host' => 'SMTP Servidor',
  'Retry' => 'Tentar novamente',
  'n/a' => 'n/a',
  'SMTP Port' => 'SMTP Porta',
  'Login' => 'Entrar',
  'Home' => 'Home',
  'Reset Confirm' => 'Confirmar redefinir',
  'Unassigned Widgets' => 'Widgets não atribuídos',
  'Enabled' => 'Habilitado',
  'Unable to find "%name%".' => 'Incapaz de encontrar "%name%".',
  'No widgets found.' => 'Nenhum widget encontrado.',
  'Disabled' => 'Desabilitado',
  '%d Bytes' => '%d Bytes',
  'Unable to block yourself.' => 'Incapaz de bloquear a si mesmo.',
  'You do not have access to the administration area of this site.' => 'Você não tem acesso à área de administração deste site.',
  '{0} %count% Files|{1} %count% File|]1,Inf[ %count% Files' => '{0} %count% Arquivos|{1} %count% Arquivo|]1,Inf[ %count% Arquivos',
  'No location found.' => 'Nenhum local encontrado.',
  'No URL given.' => 'Nenhuma URL dada.',
  'Edit' => 'Editar',
  5 => '5',
  'Access system settings' => 'Acessar ajustes do sistema',
  'Folder' => 'Pasta',
  'Check your email for the confirmation link.' => 'Verifique seu e-mail para o link de confirmação.',
  'Enable debug toolbar' => 'Ativar barra de debug',
  'Save' => 'Salvar',
  'You are already logged in.' => 'Você já esta logado.',
  'We\'ll be back soon.' => 'Estaremos de volta em breve.',
  'Menus' => 'Menus',
  'Cancel' => 'Cancelar',
  'Delete' => 'Excluir',
  'The checksum of the uploaded package does not match the one from the marketplace. The file might be manipulated.' => 'O checksum de verificação do pacote enviado não corresponde ao do marketplace. O arquivo pode ter sido manipulado.',
  'Approve Account' => 'Aprovar a conta.',
  'Select Video' => 'Selecionar Vídeo',
  'Version' => 'Versão',
  'Current Password' => 'Senha atual',
  'Number of Users' => 'Número de Usuários',
  'Directory created.' => 'Diretório criado. ',
  'Unable to upload.' => 'Não e possível enviar.',
  'Enter your database connection details.' => 'Preencha os detalhes para conexão com o Banco de dados. ',
  'Writable' => 'Gravável',
  'Active' => 'Ativo',
  'Add Role' => 'Adicionar Regra',
  '_subset' => '_subconjunto',
  'Manage menus' => 'Gerenciar Menus',
  'Successfully installed.' => 'Instalado com sucesso.',
  'Admin Locale' => 'Local do Admin',
  'Removing %title% %version%' => 'Removendo %title% %version%',
  'Cannot obtain versions. Please try again later.' => 'Não é possível obter versões. Por favor tente novamente mais tarde.',
  'Permissions' => 'Permissões',
  'Marketplace' => 'Mercado',
  '%d  GB' => '%d GB',
  '{1} %count% Widget selected|]1,Inf[ %count% Widgets selected' => '{1} %count% Widget selecionado|]1,Inf[ %count% Widgets selecionados',
  'Invalid password.' => 'Senha inválida.',
  'Edit %type%' => 'Editar  %type%',
  'From Email' => 'Do E-mail',
  'Handler' => 'Treinador',
  'Cannot connect to the marketplace. Please try again later.' => 'Não foi possível conectar-se no marketplace. Por favor tente novamente mais tarde.',
  'Insufficient User Rights.' => 'Direitos insuficiente usuário.',
  'Copy' => 'Copiar',
  'Upload complete.' => 'Envio completo.',
  'Clear' => 'Limpar',
  'Please update Pagekit to version %version%!' => 'Por favor, atualize o  Pagekit para a versão %version%!',
  'Invalid Email.' => 'Email invalido.',
  'Extension' => 'Extensão',
  'Widgets' => 'Widgets',
  'Pages moved to %menu%.' => 'Páginas movidas para %menu%.',
  'Database access denied!' => 'Acesso ao Banco de dados negado!',
  '{0} No users registered|{1} Last %users% registered user|]1,Inf[ Last %users% registered users' => '{0} Nenhum usuário registrado|{1} Último %users% usuário registrado|]1,Inf[ Últimos %users% usuários registrados',
  'Slow down a bit.' => 'Abrandar um pouco.',
  'Require e-mail verification when a guest creates an account.' => 'Pedir verificação de e-mail quando um convidado cria uma conta.',
  '%d ZB' => '%d ZB',
  'Manage users' => 'Gerenciar usuários',
  'Pagekit Installer' => 'Pagekit Instalador',
  '%d YB' => '%d YB',
  '\'composer.json\' is missing.' => '\'composer.json\' está faltando.',
  'Clear Cache' => 'Limpar o Cache',
  'PHP' => 'PHP',
  'Show' => 'Mostrar',
  'SMTP Password' => 'SMTP Senha',
  'No extension found.' => 'Nenhuma extensão encontrada.',
  'Invalid username or password.' => 'Nome de usuário ou senha inválida.',
  'Location' => 'Localização',
  'No Frontpage assigned.' => 'Nenhuma pagina principal atribuida.',
  'Sign up now' => 'Inscreva-se agora',
  'OAuth' => 'OAuth',
  15 => '15',
  'Add User' => 'Adicionar Usuário',
  'Users' => 'Usuários',
  'Role added' => 'Função adicionada',
  'Hi %username%' => 'Oi %username%',
  'URL Alias' => 'Apelido da URL',
  50 => '50',
  'User Agent' => 'User Agent',
  'Username not available.' => 'Utilizador não disponível.',
  'Block' => 'Bloquear',
  'Add Video' => 'Adicionar Vídeo',
  'Existing Pagekit installation detected. Choose different table prefix?' => 'Instalação do Pagekit existente detectado. Escolher prefixo da tabela diferente ?',
  'View' => 'Visualizar',
  'Login Redirect' => 'Login redirecionado',
  'General' => 'Geral',
  'Pagekit has been updated! Before we send you on your way, we have to update your database to the newest version.' => 'O Pagekit foi atualizado! Mas antes de liberar você, precisamos atualizar seu banco de dados para a versão mais recente.',
  '%d EB' => '%d EB',
  6 => '6',
  '- Assign -' => '- Atribuir -',
  'Unable to enable "%name%".' => 'Incapaz de habilitar "%name%".',
  'Mailer' => 'Remetente',
  'User not found.' => 'Usuário não encontrado.',
  'Extension not loaded' => 'Extensão não carregada',
  'Unable to retrieve feed data.' => 'Não é possível recuperar dados de alimentação.',
  'Permission denied.' => 'Permissão negada.',
  'Username is invalid.' => 'Nome de usuário é inválido.',
  'We\'re really happy to have you, %name%! Just login with the username %username%.' => 'Nós estamos muito felizes em ter você, %name%! Apenas acesse com o seu usuário %username%.',
  'Your email has been verified. Once an administrator approves your account, you will be notified by email.' => 'Seu e-mail foi verificada. Uma vez que um administrador aprova a sua conta, você será notificado por e-mail.',
  20 => '20',
  'Package path is missing.' => 'Caminho do pacote está faltando.',
  'No files uploaded.' => 'Nenhum arquivo enviado.',
  'User Type' => 'Tipo de usuário',
  'Unable to delete yourself.' => 'Não é possível excluir-se.',
  'Filter by' => 'Filtrar por',
  8 => '8',
  'Ok' => 'Ok',
  'No files found.' => 'Nenhum arquivo encontrado.',
  'Thumbnails View' => 'Visualização de miniaturas',
  'Activate your %site% account.' => 'Ative sua %site% conta.',
  '"composer.json" file not valid.' => '"composer.json" arquivo não valido.',
  'License:' => 'Licença:',
  'Unable to create directory.' => 'Não é possível criar diretório.',
  'Unknown error.' => 'Erro desconhecido.',
  'Blocked' => 'Bloqueado',
  'There is an update available for the uploaded package. Please consider installing it instead.' => 'Há uma atualização disponível para o pacote enviado. Por favor, considere instalá-lo em seu lugar.',
  'Add Link' => 'Adicionar Link',
  'Metric' => 'Métrica',
  'Only show on first post.' => 'Mostrar apenas no primeiro post.',
  'Sign up' => 'Inscrever-se',
  '"%title%" disabled.' => '"%title%" desativado.',
  'Reset password for %site%.' => 'Redefinir senha para %site%.',
  10 => '10',
  'Add Image' => 'Adicionar Imagem',
  'Post Content' => 'Publicar conteúdo',
  'Registration' => 'Inscrição',
  'Mail successfully sent!' => 'E-mail enviado com sucesso!',
  'Status' => 'Status',
  'Maintenance' => 'Manutenção',
  'Built On' => 'Construido em',
  'Placeholder Video' => 'Espaço reservado para Vídeo',
  'User Password Reset' => 'Redefinir senha do usuário',
  'View Details' => 'Ver Detalhes',
  'Permissions saved' => 'Permissões salvas',
  'username' => 'usuário',
  'Localization' => 'Localização',
  'Unable to activate "%name%".<br>A fatal error occured.' => 'Não é possível ativar "%name%".<br>Ocorreu um erro fatal.',
  'Invalid node type.' => 'Tipo de Node invalido.',
  '{1} %count% File selected|]1,Inf[ %count% Files selected' => '{1} %count% Arquivo selecionado|]1,Inf[ %count% Arquivos selecionados',
  'Installing "%title%"' => 'Instalando "%title%"',
  'Select' => 'Selecionar',
  'Installation failed!' => 'A Instalação falhou!',
  '%type% saved.' => '%type% salvo.',
  'Unable to send confirmation link.' => 'Não foi possível enviar o link de confirmação.',
  'Footer' => 'Rodapé',
  'Update Pagekit' => 'Atualizar  Pagekit',
  'Enter a email address.' => 'Preencha o endereço de e-mail.',
  'From Name' => 'Para o Nome',
  'You have the latest version of Pagekit.' => 'Você tem a versão mais recente do Pagekit.',
  'Move' => 'Mover',
  'Your password has been reset.' => 'Sua senha foi redefinida',
  'No database connection.' => 'Nenhuma conexão com o Banco de dados.',
  'Your user account has been created.' => 'Sua conta de usuário foi criada.',
  'Create your account' => 'Criar uma conta',
  'Invalid email address.' => 'Endereço de e-mail invalido.',
  'Appicon' => 'Appicon',
  'Your Profile' => 'seu Perfil',
  'SSL' => 'SSL',
  'Table View' => 'Visualização de Tabela',
  'User Profile' => 'Perfil de Usuário',
  'Select your site language.' => 'Selecione sua linguagem.',
  'Can\'t write config.' => 'Não é possível escrever as configurações.',
  'Insert code in the header and footer of your theme. This is useful for tracking codes and meta tags.' => 'Insira o código no cabeçalho e rodapé do seu tema. Isso é útil para códigos de rastreamento e meta tags.',
  'Username' => 'Nome de usuário',
  '{0} Logged in Users|{1} Logged in User|]1,Inf[ Logged in Users' => '{0} Usuários logados|{1} Usuário logado|]1,Inf[ Usuários logados',
  'Show only for active item' => 'Mostrar apenas os itens ativos',
  'Uninstalling "%title%"' => 'Desistalando "%title%"',
  'Updating to Pagekit %version%' => 'Atualizando para Pagekit %version%',
  'Verification' => 'Verificação',
  'Put the site offline and show the offline message.' => 'Colocar o site off-line e mostrar a mensagem off-line.',
  'Email' => 'Email',
  'New' => 'Novo',
  'Forgot Password?' => 'Esqueceu a senha?',
  'No user found.' => 'Nenhum usuário encontrado',
  'There is an update available.' => 'Há uma atualização disponível.',
  'Placeholder Image' => 'Espaço reservado para imagem',
  'Add Menu' => 'Adicionar Menu',
  30 => '30',
  'Order updated.' => 'Ordem atualizado.',
  2 => '2',
  'Redirect' => 'Redirecionar',
  'Unpublish' => 'Despublicar',
  'Nothing found.' => 'Nada encontrado.',
  'System Cache' => 'Sistema de Cache',
  'Edit User' => 'Editar Usuário',
  'Role not found.' => 'Papel não encontrado.',
  'Edit Widget' => 'Editar Widget',
  'Name' => 'Nome',
  'Please enable the PHP Open SSL extension.' => 'Por favor habilite a extensão PHP Open SSL.',
);


text:
import {axisLeft as d3axisLeft} from "d3-axis";
import {format as d3format} from "d3-format";
import {scaleLinear as d3scaleLinear} from "d3-scale";
import {AxisDescription, NoBucketIndex} from "../dataViews/axisData";
import {PlottingSurface} from "./plottingSurface";
import {D3Scale} from "./ui";
import {Histogram2DBase} from "./histogram2DBase";
import {add, assert} from "../util";

/**
 * Represents an SVG rectangle drawn on the screen.
 */
interface Box {
    xCoordinate: number | null;
    color: number;
    /**
     * Count of items represented by the rectangle.
     */
    count: number;
}

export interface BarInfo {
    colorIndex: number | null;
    count: number;
    bucketIndex: number | null;
}

/**
 * Draws the same data as a Histogram2DPlot but the bars are not stacked.
 */
export class Histogram2DBarsPlot extends Histogram2DBase {
    // The following are only set when drawing
    protected xPoints: number;
    protected yPoints: number;
    protected showMissing: boolean;

    public constructor(protected plottingSurface: PlottingSurface) {
        super(plottingSurface);
    }

    public draw(): void {
        super.draw();
        this.showMissing = false;
        this.xPoints = this.data.first.perBucket.length;
        this.yPoints = this.data.first.perBucket[0].perBucket.length;
        const missingYSum = this.data.first.perBucket.map(b => b.perMissing).reduce(add, 0);
        if (missingYSum > 0) {
            this.showMissing = true;
            this.yPoints++;
        }

        this.max = 0;
        const rects: Box[] = [];
        for (let x = 0; x < this.xPoints; x++) {
            let yTotal = 0;
            const xBuckets = this.data.first.perBucket[x];
            for (let y = 0; y < xBuckets.perBucket.length; y++) {
                const vis = xBuckets.perBucket[y];
                if (vis !== 0) {
                    const rect: Box = {
                        xCoordinate: x * (this.yPoints + 1) + y, // +1 for a space
                        color: y,
                        count: vis
                    };
                    rects.push(rect);
                    if (vis > this.max)
                        this.max = vis;
                }
                yTotal += vis;
            }
            const vis = this.data.first.perBucket[x].perMissing;
            const rec: Box = {
                xCoordinate: x * (this.yPoints + 1) + this.yPoints - 1,
                color: -1,
                count: vis
            };
            rects.push(rec);
            if (vis > this.max)
                this.max = vis;
        }
        /*
        TODO: show in a different plot
        if (this.heatmap.histogramMissingX != null) {
            xPoints++;
            for (let y = 0; y < yPoints; y++) {
                const vis = this.heatmap.histogramMissingY.buckets[y];
                const rec: Box = {
                    xCoordinate: (xPoints - 1) * y + yPoints - 1,
                    color: y,
                    count: vis
                };
                rects.push(rec);
                if (vis > this.max)
                    this.max = vis;
                this.missingDisplayed += vis;
            }
        }*/

        const displayMax = this.maxYAxis != null ? this.maxYAxis : this.max;
        this.yScale = d3scaleLinear()
            .range([this.getChartHeight(), 0]);
        this.yScale.domain([0, displayMax]);
        this.yAxis = new AxisDescription(
            d3axisLeft<number>(this.yScale)
                .tickFormat(d3format(".2s")), 1, false, null);

        const bucketCount = this.xPoints * (this.yPoints + 1); // + 1 for a space between groups
        this.barWidth = this.getChartWidth() / bucketCount;
        const scale = displayMax <= 0 ? 1 : this.getChartHeight() / displayMax;
        assert(this.barWidth > 1);

        this.plottingSurface.getChart()
            .selectAll("g")
            .data(rects)
            .enter().append("g")
            .append("svg:rect")
            .attr("x", (d: Box) => d.xCoordinate! * this.barWidth)
            .attr("y", (d: Box) => this.getChartHeight() - this.rectHeight(d, scale))
            .attr("height", (d: Box) => this.rectHeight(d, scale))
            .attr("width", this.barWidth - 1)
            .attr("fill", (d: Box) => this.color(d.color, this.data.first.perBucket[0].perBucket.length - 1))
            .attr("stroke", "black")
            .attr("stroke-width", (d: Box) => d.color < 0 ? 1 : 0)
        this.drawAxes();
    }

    public getYAxis(): AxisDescription {
        return this.yAxis;
    }

    public getYScale(): D3Scale {
        return this.yScale;
    }

    /**
     * The bar width in pixels.
     */
    public getBarWidth(): number {
        return this.barWidth;
    }

    protected rectHeight(d: Box, scale: number): number {
        return d.count * scale;
    }

    public getBarInfo(mouseX: number, dy: number): BarInfo {
        const bucketWidth = this.getChartWidth() / this.xPoints;
        let bucketIndex: number | null = Math.floor(mouseX / bucketWidth);
        const withinBucketOffset = mouseX - bucketIndex * bucketWidth;
        let colorIndex: number | null = Math.floor(withinBucketOffset / this.barWidth);
        let count = 0;

        if (colorIndex == this.yPoints) {
            colorIndex = NoBucketIndex;
        }

        if (bucketIndex >= 0 && bucketIndex < this.data.first.perBucket.length) {
            const bucket = this.data.first.perBucket[bucketIndex];
            if (this.showMissing && colorIndex == this.yPoints - 1)
                count = bucket.perMissing;
            else
                count = bucket.perBucket[colorIndex!];
        } else {
            bucketIndex = NoBucketIndex;
            colorIndex = NoBucketIndex;
        }
        return {
            colorIndex: colorIndex, // This could be null for the space between buckets
            bucketIndex: bucketIndex,
            count: count
        };
    }
}

redpajama_set_name: RedPajamaGithub


text:
using System.Collections.Generic;
using cstsd.Core.Net;

namespace cstsd.Core
{
    public interface ITypeScanner<TType>
    {
        NetAssembly GetNetAssembly(ICollection<TType> types, string assemblyName);
    }
}


text:
package com.opdar.gulosity.replication.server.protocol;

import com.opdar.gulosity.replication.base.Registry;

import java.io.IOException;
import java.io.RandomAccessFile;

/**
 * Created by 俊帆 on 2016/11/1.
 */
public class RequestLog {
    private int position;
    private int version;

    public int getPosition() {
        return position;
    }

    public RequestLog(int position) {
        this.position = position;
    }

    public byte[] read() {
        RandomAccessFile randomAccessFile = null;
        try {
            randomAccessFile = new RandomAccessFile(Registry.FILE_PATH, "r");
            randomAccessFile.seek(position);
            int length = randomAccessFile.readInt();
            byte[] b = new byte[length];
            randomAccessFile.read(b);
            return b;
        } catch (Exception ignored) {}finally {
            if(randomAccessFile != null) try {
                randomAccessFile.close();
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
        return null;
    }
}


text:
<?php

namespace DTS\eBaySDK\Trading\Enums;

/**
 *
 */
class RCSPaymentStatusCodeType
{
    const C_CANCELED = 'Canceled';
    const C_CUSTOM_CODE = 'CustomCode';
    const C_PAID = 'Paid';
    const C_PENDING = 'Pending';
}


text:
<#
.SYNOPSIS
This PowerShell script module file provides a step function to be used in a
series of executable PowerShell steps that is intended to be included in all
main PowerShell scripts that reside within the automation framework.

.DESCRIPTION
Note: This script module is NOT intended to be executed independent of another
PowerShell script referencing and using it.
#>

function Restart-PostgreSQL {
    <#
    .SYNOPSIS
    Restarts PostgreSQL database.

    .DESCRIPTION
    N/A

    .EXAMPLE
    There are no parameters for this function.

    Restart-PostgreSql
    #>

    # restart PostgreSQL
    Stop-PostgreSql
    Start-PostgreSql
}


text:
package net.jini.lookup.ui.factory;

import javax.swing.JFrame;

/**
 * UI factory for a Swing JFrame with a predetermined
 * title.
 *
 *
If the UI generated by the method declared in this interface implements
 * javax.accessibility.Accessible and supports the Java Accessibility
 * API, an AccessibleUI attribute
 * should be placed in the UIDescriptor's attributes set.
 *
 *
 */
public interface JFrameFactory extends java.io.Serializable {

    /**
     * Convenience constant to use in the toolkit
     * field of UIDescriptors that contain a
     * JFrameFactory.
     * The value of this constant is "javax.swing".
     */
    String TOOLKIT = "javax.swing";

    /**
     * Convenience constant to use in the UIFactoryTypes
     * set in the attributes set of UIDescriptors
     * that contain a JFrameFactory.
     * The value of this constant is "net.jini.lookup.ui.factory.JFrameFactory".
     */
    String TYPE_NAME = "net.jini.lookup.ui.factory.JFrameFactory";

    /**
     * Returns a JFrame with predetermined title.
     *
     * @param roleObject an object defined by the semantics of the UI role interface
     * implemented by the returned UI object. (UI role is indicated in the
     * role field of UIDescriptors.)
     *
     * @return a JFrame UI
     */
    JFrame getJFrame(Object roleObject);
}


text:
class CreateGalleries < ActiveRecord::Migration
  def self.up
    # Moved to Media Component
  end

  def self.down
  end
end


text:
<?php

namespace Mi\VideoManagerPro\SDK\Common\Subscriber;

use GuzzleHttp\Command\Event\PreparedEvent;
use GuzzleHttp\Command\Guzzle\Description;
use GuzzleHttp\Event\SubscriberInterface;
use GuzzleHttp\Stream\Stream;
use Mi\VideoManagerPro\SDK\Common\Token\OAuth2Interface;

/**
 * @author Alexander Miehe <alexander.miehe@movingimage.com>
 */
class RefreshTokenData implements SubscriberInterface
{
    private $description;
    private $refreshToken;

    /**
     * @param Description     $description
     * @param OAuth2Interface $refreshToken
     */
    public function __construct(Description $description, OAuth2Interface $refreshToken)
    {
        $this->description = $description;
        $this->refreshToken = $refreshToken;
    }

    /**
     * {@inheritdoc}
     */
    public function getEvents()
    {
        return ['prepared' => ['onPrepared', 'last']];
    }

    public function onPrepared(PreparedEvent $event)
    {
        $command = $event->getCommand();
        $operation = $this->description->getOperation($command->getName());

        if ($operation->getData('refresh-token-data') === true) {
            $event->getRequest()->setBody(Stream::factory(json_encode(['refreshToken' => $this->refreshToken->getRefreshToken()])));
        }
    }
}


text:
<?php
/**
 * HelloWorldPlugin is the parent class for every plugin.
 *
 * @author Jaisen Mathai <jaisen@jmathai.com>
 */
class HelloWorldPlugin extends PluginBase
{
  public function __construct()
  {
    parent::__construct();
  }

  public function onView()
  {
    parent::onView();
  }
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<!-- EN-Revision: 22659 -->
<!-- Reviewed: no -->
<sect2 id="zend.validate.set.notempty">
    <title>NotEmpty</title>

    <para>
        Dieser Prüfer erlaubt es zu prüfen ob ein angegebener Wert nicht leer ist. Das ist oft
        nützlich wenn man mit Formular Elementen oder anderen Benutzereingaben arbeitet, und man
        sicherstellen will das den benötigten Elementen Werte zugeordnet wurden.
    </para>

    <sect3 id="zend.validate.set.notempty.options">
        <title>Unterstützte Optionen für Zend_Validate_NotEmpty</title>

        <para>
            Die folgenden Optionen werden für <classname>Zend_Validate_NotEmpty</classname>
            unterstützt:
        </para>

        <itemizedlist>
            <listitem>
                <para>
                    <emphasis><property>type</property></emphasis>: Setzt den Typ der Prüfung
                    welcher durchgeführt wird. Für Details sollte in <link
                        linkend="zend.validate.set.notempty.types">diesem Abschnitt</link>
                    nachgesehen werden.
                </para>
            </listitem>
        </itemizedlist>
    </sect3>

    <sect3 id="zend.validate.set.notempty.default">
        <title>Standardverhalten für Zend_Validate_NotEmpty</title>

        <para>
            Standardmäßig arbeitet diese Prüfung anders als man es laut <acronym>PHP</acronym>'s
            <methodname>empty()</methodname> Funktion erwarten würde. Im speziellen evaluiert diese
            Prüfung den den Integer <emphasis>0</emphasis> und den String '<emphasis>0</emphasis>'
            als leer.
        </para>

        <programlisting language="php"><![CDATA[
$valid = new Zend_Validate_NotEmpty();
$value  = '';
$result = $valid->isValid($value);
// gibt false zurück
]]></programlisting>

        <note>
            <title>Unterschiedliches Standardverhalten zu PHP</title>

            <para>
                Ohne Angabe einer Konfiguration ist das Verhalten von
                <classname>Zend_Validate_NotEmpty</classname> anders als das von
                <acronym>PHP</acronym>.
            </para>
        </note>
    </sect3>

    <sect3 id="zend.validate.set.notempty.types">
        <title>Ändern des Verhaltens für Zend_Validate_NotEmpty</title>

        <para>
            Einige Projekte haben andere Ansichten davon was als "leerer" Wert angesehen wird: ein
            String der nur Leerzeichen enthält könnte als leer angesehen werden, oder
            <emphasis>0</emphasis> könnte als nicht leer angesehen werden (speziell für boolsche
            Sequenzen). Um den unterschiedlichen Notwendigkeiten gerecht zu werden erlaubt es
            <classname>Zend_Validate_NotEmpty</classname> die Typen zu konfigurieren welche als
            leer angesehen werden und jene die es nicht werden.
        </para>

        <para>
            Die folgenden Typen können behandelt werden:
        </para>

        <itemizedlist>
            <listitem>
                <para>
                    <emphasis>boolean</emphasis>: Gibt <constant>FALSE</constant> zurück wenn der
                    boolsche Wert <constant>FALSE</constant> ist.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>integer</emphasis>: Gibt <constant>FALSE</constant> zurück wenn ein
                    Integerwert <emphasis>0</emphasis> angegeben ist. Standardmäßig ist diese
                    Prüfung nicht aktiviert und gibt bei jedem Integerwert <constant>TRUE</constant>
                    zurück.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>float</emphasis>: Gibt <constant>FALSE</constant> zurück wenn die
                    Gleitkommazahl <emphasis>0.0</emphasis> angegeben ist. Standardmäßig ist diese
                    Prüfung nicht aktiviert und gibt bei jeder Gleitkommazahl
                    <constant>TRUE</constant> zurück.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>string</emphasis>: Gibt <constant>FALSE</constant> zurück wenn ein
                    leerer String <emphasis>''</emphasis> angegeben wird.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>zero</emphasis>: Gibt <constant>FALSE</constant> zurück wenn das
                    einzelne Zeichen Null (<emphasis>'0'</emphasis>) angegeben wird.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>empty_array</emphasis>: Gibt <constant>FALSE</constant> zurück wenn
                    ein leeres <emphasis>array</emphasis> angegeben wird.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>null</emphasis>: Gibt <constant>FALSE</constant> zurück wenn ein
                    <constant>NULL</constant> Wert angegeben wird.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>php</emphasis>: Gibt bei den gleichen Gründen
                    <constant>FALSE</constant> zurück wo auch <acronym>PHP</acronym>'s Methode
                    <methodname>empty()</methodname> <constant>TRUE</constant> zurückgeben würde.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>space</emphasis>: Gibt <constant>FALSE</constant> zurück wenn ein
                    String angegeben wird der nur Leerzeichen enthält.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>object</emphasis>: Gibt <constant>TRUE</constant> zurück wenn ein
                    Objekt angegeben wurde. <constant>FALSE</constant> wird zurückgegeben wenn
                    <property>object</property> nicht erlaubt, aber ein Objekt angegeben wurde.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>object_string</emphasis>: Gibt <constant>FALSE</constant> zurück wenn
                    ein Objekt angegeben wurde und dessen <methodname>__toString()</methodname>
                    Methode einen leeren String zurückgibt.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>object_count</emphasis>: Gibt <constant>FALSE</constant> zurück wenn
                    ein Objekt angegeben wurde, es ein <classname>Countable</classname> Interface
                    hat und seine Anzahl 0 ist.
                </para>
            </listitem>

            <listitem>
                <para>
                    <emphasis>all</emphasis>: Gibt bei allen oben stehenden Typen
                    <constant>FALSE</constant> zurück.
                </para>
            </listitem>
        </itemizedlist>

        <para>
            Alle anderen Werte geben standardmäßig <constant>TRUE</constant> zurück.
        </para>

        <para>
            Es gibt verschiedene Wege um zu wählen welche der obigen Typen geprüft werden sollen.
            Man kann ein oder mehrere Typen angeben und Sie hinzufügen, man kann ein Array angeben,
            man kann Konstanten verwenden, oder man gibt einen textuellen String an. Siehe auch die
            folgenden Beispiele:
        </para>

        <programlisting language="php"><![CDATA[
// Gibt bei 0 false zurück
$validator = new Zend_Validate_NotEmpty(Zend_Validate_NotEmpty::INTEGER);

// Gibt bei 0 oder '0' false zurück
$validator = new Zend_Validate_NotEmpty(
    Zend_Validate_NotEmpty::INTEGER + Zend_NotEmpty::ZERO
);

// Gibt bei 0 oder '0' false zurück
$validator = new Zend_Validate_NotEmpty(array(
    Zend_Validate_NotEmpty::INTEGER,
    Zend_Validate_NotEmpty::ZERO
));

// Gibt bei 0 oder '0' false zurück
$validator = new Zend_Validate_NotEmpty(array(
    'integer',
    'zero',
));
]]></programlisting>

        <para>
            Man kann auch eine Instanz von <classname>Zend_Config</classname> angeben um die
            gewünschten Typen zu setzen. Um Typen nach der Instanzierung zu setzen kann die
            Methode <methodname>setType()</methodname> verwendet werden.
        </para>
    </sect3>
</sect2>
<!--
vim:se ts=4 sw=4 et:
-->


text:
"""
Payment module for cash on delivery handling

Automatically completes every order passed.
"""

from datetime import datetime
import logging

from django.shortcuts import redirect
from django.utils.translation import ugettext_lazy as _

from plata.payment.modules.base import ProcessorBase
from plata.product.stock.models import StockTransaction
from plata.shop.models import OrderPayment

logger = logging.getLogger('plata.payment.cod')

class PaymentProcessor(ProcessorBase):
    key = 'cod'
    default_name = _('Cash on delivery')

    def process_order_confirmed(self, request, order):
        if not order.balance_remaining:
            return self.already_paid(order)

        logger.info('Processing order %s using COD' % order)

        payment = self.create_pending_payment(order)

        payment.status = OrderPayment.AUTHORIZED
        payment.authorized = datetime.now()
        payment.save()
        order = order.reload()

        self.create_transactions(order, _('sale'),
            type=StockTransaction.SALE, negative=True, payment=payment)
        self.order_paid(order, payment=payment)

        return self.shop.redirect('plata_order_success')


text:
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ca.teamdave.schwimmer.interfaces;

import edu.wpi.first.wpilibj.Solenoid;

/**
 *
 * @author leighpauls
 */
public class Hanger {
    private final Solenoid mUp;
    private final Solenoid mDown;

    public Hanger() {
        System.out.println("making Hanger");
        mUp = new Solenoid(1, 3);
        mDown = new Solenoid(1, 4);
        set(false);
    }

    final public void set(boolean up) {
        mUp.set(up);
        mDown.set(!up);
    }
}


text:
package main

import (
	"bytes"
	"fmt"
	"sort"
	"strconv"
	"strings"
)

// Tag represents a single tag.
type Tag struct {
	Name    string
	File    string
	Address string
	Type    TagType
	Fields  map[TagField]string
}

// TagField represents a single field in a tag line.
type TagField string

// Tag fields.
const (
	Access        TagField = "access"
	Signature     TagField = "signature"
	TypeField     TagField = "type"
	ReceiverType  TagField = "ctype"
	Line          TagField = "line"
	InterfaceType TagField = "ntype"
	Language      TagField = "language"
	ExtraTags     TagField = "extraTag"
)

// TagType represents the type of a tag in a tag line.
type TagType string

// Tag types.
const (
	Package     TagType = "p"
	Import      TagType = "i"
	Constant    TagType = "c"
	Variable    TagType = "v"
	Type        TagType = "t"
	Interface   TagType = "n"
	Field       TagType = "w"
	Embedded    TagType = "e"
	Method      TagType = "m"
	Constructor TagType = "r"
	Function    TagType = "f"
)

// NewTag creates a new Tag.
func NewTag(name, file string, line int, tagType TagType) Tag {
	l := strconv.Itoa(line)
	return Tag{
		Name:    name,
		File:    file,
		Address: l,
		Type:    tagType,
		Fields:  map[TagField]string{Line: l},
	}
}

// The tags file format string representation of this tag.
func (t Tag) String() string {
	var b bytes.Buffer

	b.WriteString(t.Name)
	b.WriteByte('\t')
	b.WriteString(t.File)
	b.WriteByte('\t')
	b.WriteString(t.Address)
	b.WriteString(";\"\t")
	b.WriteString(string(t.Type))
	b.WriteByte('\t')

	fields := make([]string, 0, len(t.Fields))
	i := 0
	for k, v := range t.Fields {
		if len(v) == 0 {
			continue
		}
		fields = append(fields, fmt.Sprintf("%s:%s", k, v))
		i++
	}

	sort.Sort(sort.StringSlice(fields))
	b.WriteString(strings.Join(fields, "\t"))

	return b.String()
}


text:
require 'spec_helper'

describe "cms/pages", type: :feature, dbscope: :example, js: true do
  let(:site) { cms_site }

  # check_mobile_html_size at addon body
  context "check_mobile_html_size" do
    it "on click check_size_button html_size too big" do
      site.mobile_size = 1_024
      site.save!

      login_cms_user
      visit new_cms_page_path(site)

      html_text = "
あいうえおカキクケコ

あいうえおカキクケコ

あいうえおカキクケコ
" * 10

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")
      expect(page).to have_css "form #errorMobileChecker"
      expect(page).to have_selector "form #errorMobileChecker p.error", text: /携帯で表示する場合、本文のデータサイズが(.+)/i
    end

    it "on click check_size_button html_size ok" do
      html_text = "
あいうえおカキクケコ
"

      login_cms_user
      visit new_cms_page_path(site)

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")

      expect(page).to have_css "form #errorMobileChecker"
      expect(page).to have_selector "form #errorMobileChecker p", text: I18n.t('errors.messages.mobile_size_check_size')
    end
  end

  context "check_file_size" do
    let(:file) { create(:ss_file, filename: "logo.png") }
    let(:test_file_path) { Rails.root.join("spec", "fixtures", "ss", "logo.png") }

    it "mobile_size 1" do
      site.mobile_state = "enabled"
      site.mobile_size = 1_024
      site.save!

      html_text = ""

      login_cms_user
      visit new_cms_page_path(site)

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")

      expect(page).to have_css "form #errorMobileChecker"
      expect(page).to have_selector "form #errorMobileChecker p", text: /携帯電話で表示する場合、ファイルサイズ合計(.+)/i
    end

    it "mobile_size 100" do
      site.mobile_state = "enabled"
      site.mobile_size = 100 * 1_024
      site.save!
      site.reload

      html_text = ""
      html_text += ""

      login_cms_user
      visit new_cms_page_path(site)

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")
      expect(page).to have_selector "form #errorMobileChecker p", text: I18n.t('errors.messages.mobile_size_check_size')
    end

    it "many same files in html" do
      site.mobile_state = "enabled"
      site.mobile_size = 20 * 1_024
      site.save!
      site.reload

      html_text = ""
      html_text += ""

      login_cms_user
      visit new_cms_page_path(site)

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")
      expect(page).to have_selector "#errorMobileChecker p", text: I18n.t('errors.messages.mobile_size_check_size')

      3.times.each do
        html_text += ""
      end

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")
      expect(page).to have_selector "#errorMobileChecker p", text: I18n.t('errors.messages.mobile_size_check_size')
    end

    it "many different files in html" do
      site.mobile_state = "enabled"
      site.mobile_size = 6 * 1_024
      site.save!
      site.reload

      file2 = tmp_ss_file(
        Cms::File, site: site, user: cms_user, model: "cms/file",
        contents: "#{Rails.root}/spec/fixtures/ss/file/keyvisual.jpg"
      )

      html_text = ""
      html_text += ""
      html_text += ""

      login_cms_user
      visit new_cms_page_path(site)

      fill_in_ckeditor "item[html]", with: html_text
      click_on I18n.t("cms.mobile_size_check")
      expect(page).to have_selector "form #errorMobileChecker p", text: /携帯電話で表示する場合、ファイルサイズ合計(.+)/i
    end

    it "mobile_state disabled" do
      site.mobile_state = "disabled"
      site.save!

      login_cms_user
      visit new_cms_page_path(site)

      expect(page).to have_no_text(I18n.t("cms.mobile_size_check"))
    end
  end
end


text:
this is a text flie for michael's iedas:
===

###this a consept for the code for poisoned
var a = 1.5
...
if ( player.condition.poisoned ){
var hp = player.condition.health;
hp -=a;
player.condition.health = hp;
};

###this a consept for the code for cursed
var a = 1.5
var b = (a+5)+( math.random()*10);
....
if ( player.condition.cursed ){
var hp = player.condition.health;
hp -=a*2;
player.condition.health = hp;
var mp = player.condition.magic;
mp-= b;
};

mabe these should be in there own file (effects.js maybe)

###this is old code but the same apicion is here ( as in the new code)

	switch ( key )
			{
				case 87:  // W
				case 119: // w
					objPlayer.pos.y -= player.attribute.speed;
					move = true;
					break;
				case 65:  // A
				case 97:  // a
					objPlayer.pos.x -= player.attribute.speed;
					move = true;
					break;
				case 83:  // S
				case 115: // s
					objPlayer.pos.y += player.attribute.speed;
					move = true;
					break;
				case 68:  // D
				case 100: // d
					objPlayer.pos.x += player.attribute.speed;
					move = true;
					break;
			}


text:
module Forem
  class TopicsController < Forem::ApplicationController
    helper 'forem/posts'
    before_filter :authenticate_forem_user, :except => [:show]
    before_filter :find_forum

    def show
      begin
        scope = forem_admin? ? @forum.topics : @forum.topics.visible
        @topic = scope.find(params[:id])
      rescue ActiveRecord::RecordNotFound
        flash.alert = t("forem.topic.not_found")
        redirect_to @forum
      else
        register_view
        @posts = @topic.posts.page(params[:page]).per(20)
      end
    end

    def new
      authorize! :create_topic, @forum
      @topic = @forum.topics.build
      @topic.posts.build
    end

    def create
      authorize! :create_topic, @forum
      @topic = @forum.topics.build(params[:topic])
      @topic.user = forem_user
      if @topic.save
        flash[:notice] = t("forem.topic.created")
        redirect_to [@forum, @topic]
      else
        flash.now.alert = t("forem.topic.not_created")
        render :action => "new"
      end
    end

    def destroy
      @topic = @forum.topics.find(params[:id])
      if forem_user == @topic.user || forem_user.forem_admin?
        @topic.destroy
        flash[:notice] = t("forem.topic.deleted")
      else
        flash.alert = t("forem.topic.cannot_delete")
      end

      redirect_to @topic.forum
    end

    private
    def find_forum
      @forum = Forem::Forum.find(params[:forum_id])
      authorize! :read, @forum
    end

    def register_view
      @topic.register_view_by(forem_user)
    end
  end
end


text:
#include "editor-support/cocosbuilder/CCMenuItemImageLoader.h"

using namespace cocos2d;

#define PROPERTY_NORMALDISPLAYFRAME "normalSpriteFrame"
#define PROPERTY_SELECTEDDISPLAYFRAME "selectedSpriteFrame"
#define PROPERTY_DISABLEDDISPLAYFRAME "disabledSpriteFrame"

namespace cocosbuilder {

void MenuItemImageLoader::onHandlePropTypeSpriteFrame(Node * pNode, Node * pParent, const char * pPropertyName, SpriteFrame * pSpriteFrame, CCBReader * ccbReader) {
    if(kdStrcmp(pPropertyName, PROPERTY_NORMALDISPLAYFRAME) == 0) {
        if(pSpriteFrame != NULL) {
            ((MenuItemImage *)pNode)->setNormalSpriteFrame(pSpriteFrame);
        }
    } else if(kdStrcmp(pPropertyName, PROPERTY_SELECTEDDISPLAYFRAME) == 0) {
        if(pSpriteFrame != NULL) {
            ((MenuItemImage *)pNode)->setSelectedSpriteFrame(pSpriteFrame);
        }
    } else if(kdStrcmp(pPropertyName, PROPERTY_DISABLEDDISPLAYFRAME) == 0) {
        if(pSpriteFrame != NULL) {
            ((MenuItemImage *)pNode)->setDisabledSpriteFrame(pSpriteFrame);
        }
    } else {
        MenuItemLoader::onHandlePropTypeSpriteFrame(pNode, pParent, pPropertyName, pSpriteFrame, ccbReader);
    }
}

}


text:
goog.require('goog.array');
goog.require('goog.dom');
goog.require('goog.dom.query');

goog.require('annotorious.dom');
goog.require('annotorious.events');
goog.require('annotorious.mediatypes.Module');
goog.require('annotorious.mediatypes.image.ImageModule');
goog.require('annotorious.mediatypes.openlayers.OpenLayersModule');
goog.require('annotorious.mediatypes.openseadragon.OpenSeadragonModule');

// goog.require('annotorious.Hint');

/**
 * The main entrypoint to the application. The Annotorious class is instantiated exactly once,
 * and added to the global window object as 'window.anno'. It exposes the external JavaScript API
 * and internally manages the 'modules'. (Each module is responsible for one particular media
 * type - image, OpenLayers, etc.)
 * @constructor
 */
annotorious.Annotorious = function () {
    /** @private **/
    this._isInitialized = false;

    /** @private **/
    this._modules = [new annotorious.mediatypes.image.ImageModule()];

    if (window['OpenLayers'])
        this._modules.push(new annotorious.mediatypes.openlayers.OpenLayersModule());

    if (window['OpenSeadragon'])
        this._modules.push(new annotorious.mediatypes.openseadragon.OpenSeadragonModule());

    /** @private **/
    this._plugins = [];

    var self = this;
    annotorious.dom.addOnLoadHandler(function () {
        self._init();
    });
}

annotorious.Annotorious.prototype._init = function () {
    if (this._isInitialized)
        return;

    var self = this;
    goog.array.forEach(this._modules, function (module) {
        module.init();
    });

    goog.array.forEach(this._plugins, function (plugin) {
        // if (plugin.initPlugin)
        //     plugin.initPlugin(self);

        goog.array.forEach(self._modules, function (module) {
            module.addPlugin(plugin);
        });
    });

    this._isInitialized = true;
}

/**
 * Returns the module that is in charge of handling the item with the specified
 * URL or null, if no responsible module is found.
 * @param {string} item_src the URL of the annotatable item
 * @return {Object | null}
 * @private
 */
annotorious.Annotorious.prototype._getModuleForItemSrc = function (item_src) {
    return goog.array.find(this._modules, function (module) {
        return module.annotatesItem(item_src);
    });
}

/**
 * 'Manually' actives the selector, bypassing the selection widget. Note: this also
 * works when the selection widget is hidden. Primary use case for this is for developers
 * who want to build their own selector widgets or 'Create Annotation' buttons.
 * The selector can be activated on a specific item or globally, on all items (which
 * serves mainly as a shortcut for pages where there is only one annotatable item).
 * The function can take a callback function as parameter, which will be called when the
 * selector is deactivated again.
 * @param {string | Function} opt_item_url_or_callback the URL of the item, or a callback function
 * @param {Function} opt_callback a callback function (if the first parameter was a URL)
 */
annotorious.Annotorious.prototype.activateSelector = function (opt_item_url_or_callback, opt_callback) {
    var item_url = undefined,
        callback = undefined;

    if (goog.isString(opt_item_url_or_callback)) {
        item_url = opt_item_url_or_callback;
        callback = opt_callback;
    } else if (goog.isFunction(opt_item_url_or_callback)) {
        callback = opt_item_url_or_callback;
    }

    if (item_url) {
        var module = this._getModuleForItemSrc(item_url);
        if (module)
            module.activateSelector(item_url, callback);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.activateSelector(callback);
        });
    }
}

/**
 * Adds an annotation to an item on the page.
 * @param {annotorious.Annotation} annotation the annotation
 * @param {annotorious.Annotation} opt_replace optionally, an existing annotation to replace
 */
annotorious.Annotorious.prototype.addAnnotation = function (annotation, opt_replace) {
    annotation.src = annotorious.dom.toAbsoluteURL(annotation.src);
    var module = this._getModuleForItemSrc(annotation.src);
    if (module)
        module.addAnnotation(annotation, opt_replace);
}

/**
 * Adds an event handler to Annotorious.
 * @param {annotorious.events.EventType} type the event type
 * @param {Function} handler the handler function
 */
annotorious.Annotorious.prototype.addHandler = function (type, handler) {
    goog.array.forEach(this._modules, function (module) {
        module.addHandler(type, handler);
    });
}

/**
 * Adds a plugin to Annotorious.
 * @param {string} plugin_name the plugin name
 * @param {Object} opt_config_options an optional object literal with plugin config options
 */
annotorious.Annotorious.prototype.addPlugin = function (plugin_name, opt_config_options) {
    try {
        var plugin = new window['annotorious']['plugin'][plugin_name](opt_config_options);

        if (document.readyState == 'complete') {
            // Document loaded -- init immediately
            if (plugin.initPlugin)
                plugin.initPlugin(this);

            goog.array.forEach(this._modules, function (module) {
                module.addPlugin(plugin);
            });
        } else {
            // Document not loaded yet -- defer init
            this._plugins.push(plugin);
        }
    } catch (error) {
        console.log('Could not load plugin: ' + plugin_name);
    }
}

/**
 * Destroys annotation functionality on an item, or all items on the page. Note
 * that this method differs from anno.reset() in so far as class="annotatable"
 * attributes are not re-evaluated! What is destroyed, stays destroyed - until
 * made annotatable again via anno.makeAnnotatable().
 * @param {string=} opt_item_url the URL of the item on which to destroy annotation functionality
 */
annotorious.Annotorious.prototype.destroy = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.destroy(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.destroy();
        });
    }
}

/**
 * Returns the name of the selector that is currently activated on a
 * particular item.
 * @param {string} item_url the URL of the item to query for the active selector
 */
annotorious.Annotorious.prototype.getActiveSelector = function (item_url) {
    var module = this._getModuleForItemSrc(item_url);
    if (module)
        return module.getActiveSelector(item_url);
    else
        return undefined;
}

/**
 * Returns all annotations on the annotatable item with the specified URL, or
 * all annotations on the page in case no URL is specified.
 * @param {string | undefined} opt_item_url an item URL (optional)
 * @return {Array.<annotorious.Annotation>} the annotations
 */
annotorious.Annotorious.prototype.getAnnotations = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            return module.getAnnotations(opt_item_url);
        else
            return [];
    } else {
        var annotations = [];
        goog.array.forEach(this._modules, function (module) {
            goog.array.extend(annotations, module.getAnnotations());
        });
        return annotations;
    }
}

/**
 * Returns the list of available shape selectors for a particular item.
 * @param {string} item_url the URL of the item to query for available selectors
 * @returns {Array.<string>} the list of selector names
 */
annotorious.Annotorious.prototype.getAvailableSelectors = function (item_url) {
    var module = this._getModuleForItemSrc(item_url);
    if (module)
        return module.getAvailableSelectors(item_url);
    else
        return [];
}

/**
 * Hides existing annotations on all, or a specific item.
 * @param {string} opt_item_url the URL of the item
 */
annotorious.Annotorious.prototype.hideAnnotations = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.hideAnnotations(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.hideAnnotations();
        });
    }
}

/**
 * Hides the selection widget, thus preventing users from creating new annotations.
 * The selection widget can be hidden on a specific item or globally, on all annotatable
 * items on the page.
 * @param {string | undefined} opt_item_url the URL of the item on which to hide the selection widget
 */
annotorious.Annotorious.prototype.hideSelectionWidget = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.hideSelectionWidget(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.hideSelectionWidget();
        });
    }
}

annotorious.Annotorious.prototype.stopSelection = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.stopSelection(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.stopSelection();
        });
    }
}

/**
 * Highlights the specified annotation.
 * @param {annotorious.Annotation} annotation the annotation
 */
annotorious.Annotorious.prototype.highlightAnnotation = function (annotation) {
    if (annotation) {
        var module = this._getModuleForItemSrc(annotation.src);

        if (module)
            module.highlightAnnotation(annotation);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.highlightAnnotation();
        });
    }
}

/**
 * Makes an item annotatable, if there is a module that supports the item type.
 * @param {Object} item the annotatable item
 */
annotorious.Annotorious.prototype.makeAnnotatable = function (item) {
    // Be sure to init if the load handler hasn't already taken care of it
    this._init();

    var module = goog.array.find(this._modules, function (module) {
        return module.supports(item);
    });

    if (module)
        module.makeAnnotatable(item);
    else
        throw('Error: Annotorious does not support this media type in the current version or build configuration.');
}

/**
 * Removes all annotations. If the optional parameter opt_item_url is set,
 * only the annotations on the specified item will be removed. Otherwise all
 * annotations on all items on the page will be removed.
 * @param {string} opt_item_url the src URL of the item
 */
annotorious.Annotorious.prototype.removeAll = function (opt_item_url) {
    // TODO this could be optimized a lot by adding a .removeAll method
    // to modules and annotators!
    var self = this;
    goog.array.forEach(this.getAnnotations(opt_item_url), function (annotation) {
        self.removeAnnotation(annotation);
    });
}

/**
 * Removes an annotation from an item on the page.
 * @param {annotorious.Annotation} annotation the annotation to remove
 */
annotorious.Annotorious.prototype.removeAnnotation = function (annotation) {
    var module = this._getModuleForItemSrc(annotation.src);
    if (module)
        module.removeAnnotation(annotation);
}

/**
 * Resets annotation functionality on this page. After the reset, annotation
 * functionality will be reomved from all items. Images with the 'annotatable'
 * CSS class will have been re-initialized (i.e. they will be annotatable, with
 * a fresh annotator).
 */
annotorious.Annotorious.prototype.reset = function (annotation) {
    goog.array.forEach(this._modules, function (module) {
        module.destroy();
        module.init();
    });
}

/**
 * Sets a specific selector on a particular item.
 * @param {string} item_url the URL of the item on which to set the selector
 * @param {string} selector the name of the selector to set on the item
 */
annotorious.Annotorious.prototype.setActiveSelector = function (item_url, selector) {
    var module = this._getModuleForItemSrc(item_url);
    if (module)
        module.setActiveSelector(item_url, selector);
}

/**
 * Sets system-wide properties. The 'props' object is a key/value hash and
 * supports the following properties:
 *
 * outline: outline color for annotation and selection shapes
 * stroke: stroke color for annotation and selection shapes
 * fill: fill color for annotation and selection shapes
 * hi_stroke: stroke color for highlighted annotation shapes
 * hi_fill: fill color for highlighted annotation shapes
 *
 * @param {Object} props the properties object
 */
annotorious.Annotorious.prototype.setProperties = function (props) {
    goog.array.forEach(this._modules, function (module) {
        module.setProperties(props);
    });
}

/**
 * Enables (or disables) the ability to create new annotations on an annotatable item.
 * @param {boolean} enabled if true, new annotations can be created
 *
 * !!!!
 * @deprecated will be removed in v1.0!
 * !!!!
 */
annotorious.Annotorious.prototype.setSelectionEnabled = function (enabled) {
    if (enabled)
        this.showSelectionWidget(undefined);
    else
        this.hideSelectionWidget(undefined);
}

/**
 * Shows existing annotations on all, or a specific item.
 * @param {string} opt_item_url the URL of the item
 */
annotorious.Annotorious.prototype.showAnnotations = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.showAnnotations(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.showAnnotations();
        });
    }
}

/**
 * Shows the selection widget, thus enabling users to create new annotations.
 * The selection widget can be made visible on a specific item or globally, on all
 * annotatable items on the page.
 * @param {string | undefined} opt_item_url the URL of the item on which to show the selection widget
 */
annotorious.Annotorious.prototype.showSelectionWidget = function (opt_item_url) {
    if (opt_item_url) {
        var module = this._getModuleForItemSrc(opt_item_url);
        if (module)
            module.showSelectionWidget(opt_item_url);
    } else {
        goog.array.forEach(this._modules, function (module) {
            module.showSelectionWidget();
        });
    }
}

/**
 *
 * @param opt_item_url
 * @param type_selectors
 */
annotorious.Annotorious.prototype.setTypeSelectors = function (opt_item_url, type_selectors) {
    var module = this._getModuleForItemSrc(opt_item_url);
    if (module)
        module.setTypeSelectors(opt_item_url, type_selectors);
}

// annotorious.Annotorious.prototype.hideHint = function () {
//     console.log("TODO: Remove default annotation");
// }

window['anno'] = new annotorious.Annotorious();


text:
<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~  Licensed to the Apache Software Foundation (ASF) under one
  ~  or more contributor license agreements.  See the NOTICE file
  ~  distributed with this work for additional information
  ~  regarding copyright ownership.  The ASF licenses this file
  ~  to you under the Apache License, Version 2.0 (the
  ~  "License"); you may not use this file except in compliance
  ~  with the License.  You may obtain a copy of the License at
  ~
  ~   http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~  Unless required by applicable law or agreed to in writing,
  ~  software distributed under the License is distributed on an
  ~   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  ~  KIND, either express or implied.  See the License for the
  ~  specific language governing permissions and limitations
  ~  under the License.
  -->

<!-- Introduction to the XQuery mediator -->
<definitions xmlns="http://ws.apache.org/ns/synapse">

    <!-- the SimpleURLRegistry allows access to a URL based registry (e.g. file:/// or http://) -->
    <registry provider="org.apache.synapse.registry.url.SimpleURLRegistry">
        <!-- the root property of the simple URL registry helps resolve a resource URL as root + key -->
        <parameter name="root">file:repository/conf/sample/resources/</parameter>
        <!-- all resources loaded from the URL registry would be cached for this number of milli seconds -->
        <parameter name="cachableDuration">15000</parameter>
    </registry>

    <localEntry key="xquery-key-req"
                src="file:repository/conf/sample/resources/xquery/xquery_req.xq"/>

    <proxy name="StockQuoteProxy">
        <target>
            <inSequence>
                <property name="body" expression="$body/child::*[position()=1]"/>
                <xquery key="xquery-key-req">
                    <variable name="payload" type="ELEMENT"/>
                </xquery>
                <send>
                    <endpoint>
                        <address uri="http://localhost:9000/services/SimpleStockQuoteService"/>
                    </endpoint>
                </send>
            </inSequence>
            <outSequence>
                <out>
                    <xquery key="xquery/xquery_res.xq">
                        <variable name="payload" type="ELEMENT"/>
                        <variable xmlns:m0="http://services.samples"
                                  name="code" type="STRING"
                                  expression="self::node()//m0:return/m0:symbol/child::text()"/>
                        <variable xmlns:m0="http://services.samples"
                                  name="price" type="DOUBLE"
                                  expression="self::node()//m0:return/m0:last/child::text()"/>
                    </xquery>
                    <send/>
                </out>
            </outSequence>
        </target>
        <publishWSDL uri="file:repository/conf/sample/resources/proxy/sample_proxy_1.wsdl"/>
    </proxy>

</definitions>


text:
        <?php
            echo link_tag('public/materialize/css/icon.css', 'stylesheet');
        ?>

        <?php
            echo link_tag('public/materialize/css/materialize.css');
        ?>

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

        <?php
            echo link_tag('public/css/defined.css');
        ?>
        <?php
//            echo link_tag('public/css/reset.css');
        ?>

        <img class="responsive-img logo" src="<?php echo base_url("public/media/Badge.png"); ?>" alt="FTF Logo">

<a href="<?php echo base_url();?>">Home

<?php echo anchor('landingPage_ctr/logreg', 'My account'); ?>

<?php echo anchor('landingPage_ctr/logreg', 'My cart'); ?>


text:
using System;
namespace NumbersInReversedOrder
{
    class Program
    {
        public static void Main(string[] args)
        {
            var numberToCheck = double.Parse(Console.ReadLine());
            ReversedNumbers(numberToCheck);
        }

        public static void ReversedNumbers(double number)
        {
            var toString = number.ToString();
            string reversed = string.Empty;

            foreach (char ch in toString)
            {
                reversed = ch + reversed;
            }
            Console.WriteLine(reversed);
        }
    }
}


text:
window.decimalFormatter = (function () {
    function DecimalFormatter (els) {
         //
    }

    var decimalFormatter;

    countDecimalPlaces = function(s) {
        var len = s.length;
        var pos = s.indexOf(".") + 1;
        if (pos === 0 ) { return 0; }
        return len - pos;
    };

    formatForView = function(n, d) {
        // convert to string
        var s = "" + n;

        var decimalPlaces = countDecimalPlaces(s);

        // already has two decimal places
        if (decimalPlaces === d) { return s; }

        // round if already more than d decimal places
        if (decimalPlaces > d) {
            return "" + Math.round10(n, -d);
        }

        // has no decimal places, add a dot
        if (decimalPlaces === 0) {
            s = addDot(s);
            // make sure there is a leading number
            if (s === ".") {
                s = "0.";
            }
        }

        // fill with zeros to d places
        while(countDecimalPlaces(s) < d) {
            s = addZero(s);
        }

        return s;
    };

    addDot = function(s) {
        return s + ".";
    };

    addZero = function(s) {
        return s + "0";
    };

    decimalFormatter = {
        format: function (value, decimalPlaces) {
            return formatForView(value, decimalPlaces);
        }
    };

    return decimalFormatter;
}());


text:
from pyosmo.error_strategy.base import OsmoErrorStrategy
from pyosmo.history.history import OsmoHistory
from pyosmo.model import OsmoModelCollector

class AlwaysRaise(OsmoErrorStrategy):
    """
    Just raise the exception always, which stops osmo execution
    """

    def failure_in_test(self, history: OsmoHistory, model: OsmoModelCollector, error: Exception):
        raise error

    def failure_in_suite(self, history: OsmoHistory, model: OsmoModelCollector, error: Exception):
        raise error


text:
package com.github.franciscan.remotetile.fragment;

import android.content.DialogInterface;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.text.Editable;
import android.text.TextWatcher;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.EditText;
import android.widget.GridView;
import android.widget.ImageView;
import android.widget.TextView;

import com.afollestad.materialdialogs.MaterialDialog;
import com.github.franciscan.remotetile.R;
import com.github.franciscan.remotetile.adapter.IconsAdapter;
import com.github.franciscan.remotetile.utils.Constant;
import com.github.franciscan.remotetile.utils.Datastore;
import com.github.franciscan.remotetile.utils.Icons;

import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;

/**
 * Created by Francesco Cannizzaro on 01/02/2016.
 */
public class Editor extends Fragment implements View.OnClickListener, DialogInterface.OnDismissListener {

    private static HashMap<String, List<Integer>> icons = null;
    private int icon = R.drawable.ic_info_outline_white_24dp;
    private MaterialDialog dialog, dialogChooser;
    private GridView gvIcons;
    private ImageView ivIcon;
    private String event, data;
    private IconsAdapter adapter;
    private EditText evEvent, evData;

    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        View v = inflater.inflate(R.layout.fragment_editor, container, false);

        // find views
        evEvent = (EditText) v.findViewById(R.id.ev_event);
        evData = (EditText) v.findViewById(R.id.ev_data);
        TextView tvEvent = (TextView) v.findViewById(R.id.event);
        TextView tvData = (TextView) v.findViewById(R.id.data);
        ivIcon = (ImageView) v.findViewById(R.id.icon);

        // link with listener
        v.findViewById(R.id.btn_icon).setOnClickListener(this);
        v.findViewById(R.id.fab).setOnClickListener(this);
        link(evData, tvData);
        link(evEvent, tvEvent);

        // find & fill with current values
        if (getArguments() != null) {
            event = getArguments().getString(Constant.EVENT_EXTRA);
            data = getArguments().getString(Constant.DATA_EXTRA);
            icon = getArguments().getInt(Constant.ICON_EXTRA);
            evData.setText(data);
            tvData.setText(data);
            evEvent.setText(event);
            tvEvent.setText(event);
            if (icon != 0) {
                ivIcon.setImageResource(icon);
                ivIcon.setTag(icon);
            }
        }

        // create icons chooser
        dialog = new MaterialDialog.Builder(getActivity())
                .customView(R.layout.content_dialog, false)
                .dismissListener(Editor.this)
                .backgroundColorRes(R.color.dark_background)
                .build();

        assert dialog.getCustomView() != null;
        gvIcons = (GridView) dialog.getCustomView().findViewById(R.id.gv_icons);

        dialogChooser = new MaterialDialog.Builder(getActivity())
                .title("Choose Icon Category")
                .items(Icons.categories)
                .itemsColorRes(android.R.color.white)
                .titleColorRes(android.R.color.white)
                .backgroundColorRes(R.color.dark_background)
                .itemsCallback(new MaterialDialog.ListCallback() {
                    @Override
                    public void onSelection(MaterialDialog d, View itemView, int which, CharSequence text) {
                        generateIconsIdentifiers();
                        String key = text.toString();
                        adapter = new IconsAdapter(getActivity(), icons.get(key), ivIcon, dialog);
                        gvIcons.setAdapter(adapter);
                        dialog.show();
                    }
                })
                .build();

        new Thread(new Runnable() {
            @Override
            public void run() {
                generateIconsIdentifiers();
            }
        }).start();

        return v;
    }

    /**
     * Link Editext changes to TextView text     *
     */
    private void link(EditText ev, final TextView tv) {
        ev.addTextChangedListener(new TextWatcher() {
            @Override
            public void beforeTextChanged(CharSequence charSequence, int i, int i1, int i2) {
            }

            @Override
            public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {
                tv.setText(charSequence.toString());
            }

            @Override
            public void afterTextChanged(Editable editable) {
            }
        });
    }

    /**
     * Create Hashmap (category based) of drawable id from drawable strings
     */
    private void generateIconsIdentifiers() {

        if (icons != null)
            return;

        int id;
        icons = new HashMap<>();

        for (int j = 0; j < Icons.get.length; j++) {
            List<Integer> list = new LinkedList<>();

            for (int i = 0; i < Icons.get[j].length; i++)
                if ((id = getResources().getIdentifier(Icons.get[j][i], "drawable", "com.github.franciscan.remotetile")) != 0)
                    list.add(id);

            icons.put(Icons.categories[j], list);
        }
    }

    /**
     * Get String from EditText
     */
    private String getText(EditText e) {
        return e.getText().toString();
    }

    /**
     * Save command
     */
    private void save() {

        Datastore.getInstance().remove(event, data);

        String event = getText(evEvent),
                data = getText(evData);

        if (event.isEmpty())
            return;

        Datastore.getInstance().add(event, data, icon);
        getActivity().onBackPressed();

    }

    @Override
    public void onClick(View view) {
        if (view.getId() == R.id.fab)
            save();
        else if (dialogChooser != null)
            dialogChooser.show();
    }

    /**
     * Get last icon id after chooser dialog is closed
     */
    @Override
    public void onDismiss(DialogInterface dialogInterface) {
        if (ivIcon.getTag() != null)
            icon = (Integer) ivIcon.getTag();
    }
}


text:
<?php

if (!defined('WPO_VERSION')) die('No direct access allowed');

global $wpo_backup_initialized, $wpo_take_backup_checkbox_id;

$updraftplus_admin = !empty($GLOBALS['updraftplus_admin']) ? $GLOBALS['updraftplus_admin'] : null;
$updraftplus = !empty($GLOBALS['updraftplus']) ? $GLOBALS['updraftplus'] : null;

// Check if UpdraftPlus plugin status.
$updraftplus_status = $this->is_installed('UpdraftPlus - Backup/Restore');
$check_version = false;

// If UpdraftPlus Admin exists along with Method and active, then call the update modal.
if (is_a($updraftplus_admin, 'UpdraftPlus_Admin') && is_callable(array($updraftplus_admin, 'add_backup_scaffolding'))) {
	if (!$wpo_backup_initialized) {
		$updraftplus_admin->add_backup_scaffolding(__('Backup before running optimizations', 'wp-optimize'), array($updraftplus_admin, 'backupnow_modal_contents'));
	}
	$wpo_backup_initialized = true;
	$check_version = true;
} else {

	// When pulling this template from UDC-RPC it gives $updraftplus_admin as null and the above condition
	// will always result into $disabled_backup = 'disabled', making the backup checkbox on UDC unclickable,
	// this makes sense since we're not logging directly into the admin dashboard but through UDC. Since,
	// we're giving the user an option to make a backup using UDP before optimizing on UDC, therefore we
	// need a way to enable the checkbox (making it clickable), giving control to the user whether he or she
	// needs to backup before running the optimization process.
	//
	// Having to check whether UDP is installed and active is enough for UDC to run its local backup process
	// if the user wishes to backup before optimizing. Of course, when $updraftplus_admin is null we assumed
	// that the request is coming from UDC-RPC.
	if (null === $updraftplus_admin && true === $updraftplus_status['installed'] && true === $updraftplus_status['active']) {
		$disabled_backup = '';
		$check_version = true;

	} else {
		// Disabled UpdraftPlus.
		$disabled_backup = 'disabled';
	}
}

if (true === $check_version) {
	// Check version.
	if (version_compare($updraftplus->version, '1.12.33', '<')) {
		$disabled_backup = 'disabled';
		$updraftplus_version_check = true;
	} else {
		$disabled_backup = '';
		$updraftplus_version_check = false;
	}
}

if (!is_int($wpo_take_backup_checkbox_id)) {
	$wpo_take_backup_checkbox_id = 0;
} else {
	$wpo_take_backup_checkbox_id++;
}

$wpo_take_backup_checkbox_dom_id = 'enable-auto-backup'.($wpo_take_backup_checkbox_id > 0 ? '-'.$wpo_take_backup_checkbox_id : '');

$label_text = (isset($label) && '' !== $label) ? $label : __('Take a backup with UpdraftPlus before doing this', 'wp-optimize');

if (!isset($default_checkbox_value)) {
	$default_checkbox_value = 'false';
}
?>

	<input class="enable-auto-backup" name="<?php echo $wpo_take_backup_checkbox_dom_id; ?>" id="<?php echo $wpo_take_backup_checkbox_dom_id; ?>" type="checkbox" value="true" <?php echo ($options->get_option($wpo_take_backup_checkbox_dom_id, $default_checkbox_value) == 'true') ? 'checked="checked"' : ''; ?> <?php echo $disabled_backup; ?> />
	<label for="<?php echo $wpo_take_backup_checkbox_dom_id; ?>"> <?php echo $label_text; ?>

	<?php
	// UpdraftPlus is not installed.
	if ('disabled' == $disabled_backup && !$updraftplus_status['installed']) {
		echo ' '.__('Follow this link to install UpdraftPlus, to take a backup before optimization', 'wp-optimize').' ';
	} else {
		// Build activate url.
		$activate_url = add_query_arg(array(
			'_wpnonce'    => wp_create_nonce('activate-plugin_updraftplus/updraftplus.php'),
			'action'      => 'activate',
			'plugin'      => 'updraftplus/updraftplus.php'
		), network_admin_url('plugins.php'));

		// If is network admin then add to link newtwork activation.
		if (is_network_admin()) {
			$activate_url = add_query_arg(array('networkwide' => 1), $activate_url);
		}

		// Check updraftplus version first.
		if (!empty($updraftplus_version_check)) {
			echo ''.__('UpdraftPlus needs to be updated to 1.12.33 or higher in order to backup the database before optimization.', 'wp-optimize').' '.__('Please update UpdraftPlus to the latest version.', 'wp-optimize').'';
		} else {
			if ($updraftplus_status['installed'] && !$updraftplus_status['active']) {
				echo ' '.__('UpdraftPlus is installed but currently not active. Follow this link to activate UpdraftPlus, to take a backup before optimization.', 'wp-optimize').' ';
			}
		}
	}
	?>


text:
package com.diaodu.dao;

import java.sql.SQLException;
import java.util.List;

import com.diaodu.domain.Batch;

public interface BatchDao {

	public List<Batch> getAllBatch()  throws SQLException ;
	public Batch getBatchByID(String id) throws SQLException;
	public Integer addBatch(Batch b) throws SQLException;
	public int deleteBatch(int id) throws SQLException;
	public int updateBatch(Batch b) throws SQLException;
}


text:
namespace Rebus.Snoop.ViewModel.Models
{
    public class Notification
    {
        readonly string headline;
        readonly string fullText;

        public Notification(string headline)
            : this(headline, null)
        {
        }

        public Notification(string headline, string fullText)
        {
            this.headline = headline;
            this.fullText = fullText;
        }

        public string Headline
        {
            get { return headline; }
        }

        public string FullText
        {
            get { return fullText; }
        }
    }
}


text:
'use strict';

// Arts controller
angular.module('arts').controller('ArtsController', ['$scope', '$stateParams', '$location', 'Authentication', 'Arts',
	function($scope, $stateParams, $location, Authentication, Arts) {
		$scope.authentication = Authentication;

		// Create new Art
		$scope.create = function() {
			// Create new Art object
			var art = new Arts ({
				name: this.name
			});

			// Redirect after save
			art.$save(function(response) {
				$location.path('arts/' + response._id);

				// Clear form fields
				$scope.name = '';
			}, function(errorResponse) {
				$scope.error = errorResponse.data.message;
			});
		};

		// Remove existing Art
		$scope.remove = function(art) {
			if ( art ) {
				art.$remove();

				for (var i in $scope.arts) {
					if ($scope.arts [i] === art) {
						$scope.arts.splice(i, 1);
					}
				}
			} else {
				$scope.art.$remove(function() {
					$location.path('arts');
				});
			}
		};

		// Update existing Art
		$scope.update = function() {
			var art = $scope.art;

			art.$update(function() {
				$location.path('arts/' + art._id);
			}, function(errorResponse) {
				$scope.error = errorResponse.data.message;
			});
		};

		// Find a list of Arts
		$scope.find = function() {
			$scope.arts = Arts.query();
		};

		// Find existing Art
		$scope.findOne = function() {
			$scope.art = Arts.get({
				artId: $stateParams.artId
			});
		};
	}
]);


text:
class UserParameters < BaseParameters

  def self.permitted
    [:id, :first_name, :last_name, :email, :phone, :http, :https, :password, :pref_distance_unit, :pref_elevation_unit]
  end
end


text:
<?php

/**
 * @category   Zend
 * @package    Zend_Validate
 * @copyright  Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
 */
class TA_Form_Validator_Uuid extends Zend_Validate_Abstract
{
    /**
     * Validation failure message key for when the value contains non-alphabetic
     * or non-digit characters
     */
    const NOT_UUID = 'notUuid';

    /**
     * Validation failure message key for when the value is an empty string
     */
    const STRING_EMPTY = 'stringEmpty';

    /**
     * Validation failure message template definitions
     *
     * @var array
     */
    protected $_messageTemplates = array(
        self::NOT_UUID     => "'%value%' is not a valid UUID",
        self::STRING_EMPTY => "'%value%' is an empty string"
    );

    /**
     * Sets default option values for this instance
     *
     * @return void
     */
    public function __construct()
    {
    }

    /**
     * Defined by Zend_Validate_Interface
     *
     * Returns true if and only if $value contains a valid UUID
     *
     * @param  string $value
     *
     * @return boolean
     */
    public function isValid($value)
    {
        $value = (string) $value;

        $this->_value = $value;

        // check if string is empty
        if (!strlen($value)) {
            $this->_error(self::STRING_EMPTY);
            return false;
        }

        if (function_exists('uuid_is_valid') && !uuid_is_valid($value))
        {
            $this->_error(self::NOT_UUID);
            return false;
        }

        // check length
        if (strlen($value) !== 36) {
            $this->_error(self::NOT_UUID);
            return false;
        }

        // are there some invalid characters
        $pattern = '/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i';
        if (!preg_match($pattern, $value)) {
            $this->_error(self::NOT_UUID);
            return false;
        }

        return true;
    }
}


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

namespace Almond.ProtocolDriver.Packets
{
    /// <summary>
    /// Represents a row paket in the result set sent by the server.
    /// </summary>
    public class Row : IServerPacket, IRow
    {
        #region Members
        private Lazy<RowReader> _reader;
        private RowReader Reader
        {
            get
            {
                if (_reader != null)
                    return _reader.Value;
                throw new ProtocolException("No row data");
            }
        }

        private Encoding Encoding
        {
            get; set;
        }
        #endregion

        #region IRow
        public ArraySegment<byte> Value(int i, Encoding encodingOverride, IList<ColumnDefinition> Columns)
        {
            return Reader.Values[i];
        }

        public string StringValue(int i, Encoding encodingOverride, IList<ColumnDefinition> Columns)
        {
            ArraySegment<byte> value = Value(i, encodingOverride, Columns);
            if (value == LineDriver.ChunkReader.NULL)
                return null;
            return ChunkReader.BytesToString(value, encodingOverride ?? Encoding);
        }
        #endregion

        #region IServerPacket
        public IServerPacket FromWireFormat(ChunkReader reader, UInt32 payloadLength, ProtocolDriver driver)
        {
            Encoding = driver.ClientEncoding;
            byte header = reader.PeekByte();
            if (header == 0)
                return (new OK()).FromWireFormat(reader, payloadLength, driver);
            else if (header == 0xFF)
                return (new ERR()).FromWireFormat(reader, payloadLength, driver);
            else if (header == 0xFE &&
                (payloadLength == 7 ||
                (payloadLength == 5 && !driver.ClientCapability.HasFlag(Capability.CLIENT_PROTOCOL_41))))
                return (new EOF()).FromWireFormat(reader, payloadLength, driver);

            ArraySegment<byte> payload = reader.ReadMyStringFix(payloadLength);

            _reader = new Lazy<RowReader>(() => new RowReader(payload));
            return this;
        }
        #endregion

        /// <summary>
        /// Nested class to convert buffered data to CLR objects.
        /// </summary>
        public class RowReader
        {
            public IList<ArraySegment<byte>> Values
            {
                get; private set;
            }

            public RowReader(ArraySegment<byte> rowData)
            {
                ChunkReader reader = new ChunkReader(rowData);

                // Null row
                if (reader.PeekByte() == 0xFB)
                    return;

                Values = new List<ArraySegment<byte>>();
                ArraySegment<byte> data;
                while (reader.ReadSoFar() != rowData.Count)
                {
                    byte peek = reader.PeekByte();
                    if (peek == 0xFB)
                    {
                        data = LineDriver.ChunkReader.NULL;
                        reader.ReadByte();
                    }
                    else
                    {
                        data = reader.ReadMyStringLenEnc();
                    }

                    Values.Add(data);
                }
            }
        }
    }
}


text:
class Agreement < Report

  def approve!(stage, comment)
    stage_prefix = stage == :initial ? '' : "#{stage}_"

    update(
      "#{stage_prefix}approved_comment" => comment,
      "#{stage_prefix}approved_at" => Time.now,
      "#{stage_prefix}approved_snapshot_agreement" => agreement
    )
  end

end


text:
class PHPWriter:
    def __init__(self, constants):
        self.constants = constants

    def write(self, out):
        out.write("<?php\n")
        out.write("/* This file was generated by generate_constants. */\n\n")

        for enum in self.constants.enum_values.values():
            out.write("\n")
            for name, value in enum.items():
                out.write("define('{}',        {});\n".format(name, value))

        for name, value in self.constants.constant_values.items():
            out.write("define('{}',        {});\n".format(name, value))


text:
require 'spec_helper'

require 'puppet/reports'
require 'time'
require 'pathname'
require 'tempfile'
require 'fileutils'

processor = Puppet::Reports.report(:store)

describe processor do
  describe "#process" do
    include PuppetSpec::Files
    before :each do
      Puppet[:reportdir] = File.join(tmpdir('reports'), 'reports')
      @report = YAML.load_file(File.join(PuppetSpec::FIXTURE_DIR, 'yaml/report2.6.x.yaml')).extend processor
    end

    it "should create a report directory for the client if one doesn't exist" do
      @report.process

      File.should be_directory(File.join(Puppet[:reportdir], @report.host))
    end

    it "should write the report to the file in YAML" do
      Time.stubs(:now).returns(Time.parse("2011-01-06 12:00:00 UTC"))
      @report.process

      File.read(File.join(Puppet[:reportdir], @report.host, "201101061200.yaml")).should == @report.to_yaml
    end

    it "rejects invalid hostnames" do
      @report.host = ".."
      Puppet::FileSystem.expects(:exist?).never
      expect { @report.process }.to raise_error(ArgumentError, /Invalid node/)
    end
  end

  describe "::destroy" do
    it "rejects invalid hostnames" do
      Puppet::FileSystem.expects(:unlink).never
      expect { processor.destroy("..") }.to raise_error(ArgumentError, /Invalid node/)
    end
  end

  describe "::validate_host" do
    ['..', 'hello/', '/hello', 'he/llo', 'hello/..', '.'].each do |node|
      it "rejects #{node.inspect}" do
        expect { processor.validate_host(node) }.to raise_error(ArgumentError, /Invalid node/)
      end
    end

    ['.hello', 'hello.', '..hi', 'hi..'].each do |node|
      it "accepts #{node.inspect}" do
        processor.validate_host(node)
      end
    end
  end
end


text:
require 'xrvg'
include XRVG

render = SVGRender[ :filename, "hellocrown2.svg" ]
SyncS[Circle[], (0.2..0.1)].samples( 10 ) do |point, radius|
  render.add( Circle[:center, point, :radius, radius ], Style[ :fill, Color.blue( 0.5 ) ] )
end
render.end


text:
<document>
  <test>Zut Alors!</test>
</document>