text:
-- phpMyAdmin SQL Dump
-- version 4.3.11
-- http://www.phpmyadmin.net
--
-- Servidor: 127.0.0.1
-- Tiempo de generación: 24-09-2015 a las 00:01:45
-- Versión del servidor: 5.5.36
-- Versión de PHP: 5.6.8

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;

--
-- Base de datos: `ssi_bd`
--

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_acceso`
--

CREATE TABLE IF NOT EXISTS `tb_acceso` (
  `idAcceso` int(11) NOT NULL,
  `descripcionAcceso` varchar(100) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_atencion_basica`
--

CREATE TABLE IF NOT EXISTS `tb_atencion_basica` (
  `codAtencionBasica` int(11) NOT NULL,
  `fechaAtencionBasica` date DEFAULT NULL,
  `horaAtencionBasica` time DEFAULT NULL,
  `curacion` text,
  `glucemia` int(11) DEFAULT NULL,
  `heparina` text,
  `higiene` text,
  `presion` int(11) DEFAULT NULL,
  `temperatura` int(11) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_cama`
--

CREATE TABLE IF NOT EXISTS `tb_cama` (
  `nroCama` int(11) NOT NULL,
  `cama` int(11) NOT NULL,
  `idEstadoCama` int(11) NOT NULL,
  `codHabitacion` int(11) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_cama`
--

INSERT INTO `tb_cama` (`nroCama`, `cama`, `idEstadoCama`, `codHabitacion`) VALUES
(1, 1, 1, 3),
(4, 1, 1, 4),
(5, 2, 1, 6);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_condicion_alta`
--

CREATE TABLE IF NOT EXISTS `tb_condicion_alta` (
  `codCondicionAlta` int(11) NOT NULL,
  `descripcionCA` varchar(100) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_enfermedad`
--

CREATE TABLE IF NOT EXISTS `tb_enfermedad` (
  `codEnfermedad` int(11) NOT NULL,
  `nombreEnfermedad` varchar(45) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=47 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_enfermedad`
--

INSERT INTO `tb_enfermedad` (`codEnfermedad`, `nombreEnfermedad`) VALUES
(1, 'Anorexia'),
(2, 'Autismo'),
(3, 'Alzhéimer'),
(4, 'Bronquiolitis'),
(5, 'Bulimia'),
(6, 'Bronquitis'),
(7, 'Cancer de Cólon'),
(8, 'Cistitis'),
(9, 'Celiaquía'),
(10, 'Diabetes'),
(11, 'Depresión'),
(12, 'Diverticulosis'),
(13, 'Ébola'),
(14, 'Edema Pulmonar'),
(15, 'EPOC'),
(16, 'Faringitis'),
(17, 'FAEQWF'),
(19, 'Gastritis'),
(20, 'Gripe'),
(21, 'Hipertensión Arterial'),
(22, 'Hemofilia'),
(23, 'Hepatitis'),
(24, 'Insuficiencia Renal Crónica'),
(25, 'Infarto de Miocardio'),
(26, 'Intoxicación Etílica'),
(27, 'Insuficiencia Cardíaca'),
(28, 'Leucemia'),
(29, 'Lipotimia'),
(30, 'Migraña'),
(31, 'Meningitis'),
(32, 'Neumonía'),
(33, 'Osteoporosis'),
(34, 'Pancreatitis'),
(35, 'Paperas'),
(36, 'Pólipos Uterinos'),
(37, 'Rubéola'),
(38, 'Rinitis'),
(39, 'Síndrome de X Frágil'),
(40, 'Sarampión'),
(41, 'SIDA'),
(42, 'Toxoplasmosis'),
(43, 'Trastorno Bipolar'),
(44, 'Tendinitis'),
(45, 'Tuberculosis'),
(46, '');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_enfermero`
--

CREATE TABLE IF NOT EXISTS `tb_enfermero` (
  `codResponsable` int(11) NOT NULL,
  `nroLegajo` int(11) NOT NULL,
  `codServicio` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_enfermero`
--

INSERT INTO `tb_enfermero` (`codResponsable`, `nroLegajo`, `codServicio`) VALUES
(21, 2313, 5),
(22, 2314, 14);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_especialidad`
--

CREATE TABLE IF NOT EXISTS `tb_especialidad` (
  `codEspecialidad` int(11) NOT NULL,
  `nombreEspecialidad` varchar(100) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_especialidad`
--

INSERT INTO `tb_especialidad` (`codEspecialidad`, `nombreEspecialidad`, `usrCarga`, `fecCarga`) VALUES
(1, 'Cardiologo', NULL, NULL),
(2, 'Traumatologo', NULL, NULL),
(3, 'Endocrinologo', NULL, NULL),
(4, 'Pediatra', NULL, NULL),
(5, 'Obstetra', NULL, NULL),
(6, 'Oncologo', NULL, NULL),
(7, 'Cirujano', NULL, NULL),
(8, 'Otorrinolaringolo', NULL, NULL),
(9, 'Psiquiatra', NULL, NULL),
(10, 'Oftalmologo', NULL, NULL);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_estado_cama`
--

CREATE TABLE IF NOT EXISTS `tb_estado_cama` (
  `idEstadoCama` int(11) NOT NULL,
  `descripcionEC` varchar(100) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_estado_cama`
--

INSERT INTO `tb_estado_cama` (`idEstadoCama`, `descripcionEC`) VALUES
(1, 'Disponible'),
(2, 'Reservada'),
(3, 'Ocupada');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_estado_etiqueta_rfid`
--

CREATE TABLE IF NOT EXISTS `tb_estado_etiqueta_rfid` (
  `codEstadoEtiqueta` int(11) NOT NULL,
  `descripcionEstadoEtiqueta` varchar(50) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_estado_etiqueta_rfid`
--

INSERT INTO `tb_estado_etiqueta_rfid` (`codEstadoEtiqueta`, `descripcionEstadoEtiqueta`) VALUES
(1, 'Fugado'),
(2, 'Internado'),
(3, 'Alta');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_etiqueta_rfid`
--

CREATE TABLE IF NOT EXISTS `tb_etiqueta_rfid` (
  `nroEtiqueta` int(11) NOT NULL,
  `nroInternacion` int(11) NOT NULL,
  `codEstadoEtiqueta` int(11) NOT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_etiqueta_rfid`
--

INSERT INTO `tb_etiqueta_rfid` (`nroEtiqueta`, `nroInternacion`, `codEstadoEtiqueta`, `usrCarga`, `fecCarga`) VALUES
(1, 1, 1, NULL, NULL),
(2, 3, 1, NULL, NULL),
(3, 4, 1, NULL, NULL);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_funcionalidad`
--

CREATE TABLE IF NOT EXISTS `tb_funcionalidad` (
  `idFuncionalidad` int(11) NOT NULL,
  `descripcionFuncionalidad` varchar(100) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_habitacion`
--

CREATE TABLE IF NOT EXISTS `tb_habitacion` (
  `codHabitacion` int(11) NOT NULL,
  `nroHabitacion` int(11) NOT NULL,
  `codServicio` int(11) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_habitacion`
--

INSERT INTO `tb_habitacion` (`codHabitacion`, `nroHabitacion`, `codServicio`) VALUES
(3, 1, 1),
(4, 2, 2),
(5, 1, 2),
(6, 1, 1);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_historia_clinica_internacion`
--

CREATE TABLE IF NOT EXISTS `tb_historia_clinica_internacion` (
  `nroHCI` int(11) NOT NULL,
  `codPaciente` int(11) NOT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_historia_clinica_internacion`
--

INSERT INTO `tb_historia_clinica_internacion` (`nroHCI`, `codPaciente`, `usrCarga`, `fecCarga`) VALUES
(2, 18, NULL, NULL),
(3, 19, NULL, NULL),
(4, 20, NULL, NULL),
(5, 21, NULL, NULL),
(6, 22, NULL, NULL);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_indicacion`
--

CREATE TABLE IF NOT EXISTS `tb_indicacion` (
  `codIndicacion` int(11) NOT NULL,
  `descripcionIndicacion` text,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_indicacion_recetada`
--

CREATE TABLE IF NOT EXISTS `tb_indicacion_recetada` (
  `codIndicacionRecetada` int(11) NOT NULL,
  `descripcionIndicacionRecetada` text,
  `codIndicacion` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_internacion`
--

CREATE TABLE IF NOT EXISTS `tb_internacion` (
  `nroInternación` int(11) NOT NULL,
  `medicoAlta` int(11) DEFAULT NULL,
  `nroHCI` int(11) DEFAULT NULL,
  `codCondicionAlta` int(11) DEFAULT NULL,
  `fechaIngreso` date DEFAULT NULL,
  `horaIngreso` time DEFAULT NULL,
  `fechaEgreso` date DEFAULT NULL,
  `horaEgreso` time DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codTratamiento` int(11) DEFAULT NULL,
  `nroCama` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_internacion_detalle`
--

CREATE TABLE IF NOT EXISTS `tb_internacion_detalle` (
  `nroDetalleInternacion` int(11) NOT NULL,
  `nroInternacion` int(11) DEFAULT NULL,
  `fechaDetalle` date DEFAULT NULL,
  `horaDetalle` time DEFAULT NULL,
  `observacionDetalleInternacion` text,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codTipoDI` int(11) DEFAULT NULL,
  `codMedicamentoRecetado` int(11) DEFAULT NULL,
  `codPedidoPracticaMedica` int(11) DEFAULT NULL,
  `codIndicacionRecetada` int(11) DEFAULT NULL,
  `codAtencionBasica` int(11) DEFAULT NULL,
  `codResponsable` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_lista_accesos`
--

CREATE TABLE IF NOT EXISTS `tb_lista_accesos` (
  `idListaAccesos` int(11) NOT NULL,
  `fecha` datetime DEFAULT NULL,
  `url` text,
  `idAcceso` int(11) DEFAULT NULL,
  `idNivel` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_lista_funcionalidades`
--

CREATE TABLE IF NOT EXISTS `tb_lista_funcionalidades` (
  `idListaFuncionalidades` int(11) NOT NULL,
  `fecha` datetime DEFAULT NULL,
  `url` text,
  `idFuncionalidad` int(11) DEFAULT NULL,
  `idNivel` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_lista_visibilidades`
--

CREATE TABLE IF NOT EXISTS `tb_lista_visibilidades` (
  `idListaVisibilidades` int(11) NOT NULL,
  `fecha` datetime DEFAULT NULL,
  `url` text,
  `idVisibilidad` int(11) DEFAULT NULL,
  `idNivel` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_localidad`
--

CREATE TABLE IF NOT EXISTS `tb_localidad` (
  `codLocalidad` int(11) NOT NULL,
  `nombreLocalidad` varchar(100) NOT NULL,
  `codProvincia` int(11) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_localidad`
--

INSERT INTO `tb_localidad` (`codLocalidad`, `nombreLocalidad`, `codProvincia`) VALUES
(1, 'Lujan de Cuyo', 1),
(2, 'Godoy Cruz', 1),
(3, 'Guaymallén', 1),
(4, 'Maipú', 1),
(5, 'Las Heras', 1),
(6, 'Villa Rumipal', 2),
(7, 'Villa Maria', 2),
(8, 'Carlos Paz', 2),
(9, 'San Francisco', 2),
(10, 'Tunuyán', 1);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_medicamento`
--

CREATE TABLE IF NOT EXISTS `tb_medicamento` (
  `codMedicamento` int(11) NOT NULL,
  `codViaAdministracion` int(11) DEFAULT NULL,
  `nombreGenerico` text,
  `nombreMedicamento` text,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codPresentacion` int(11) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=110 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_medicamento`
--

INSERT INTO `tb_medicamento` (`codMedicamento`, `codViaAdministracion`, `nombreGenerico`, `nombreMedicamento`, `usrCarga`, `fecCarga`, `codPresentacion`) VALUES
(56, 3, 'Ibuprofeno2', 'Ibu800', NULL, NULL, 3),
(59, 2, 'Ibuprofeno2', 'Ibu800', NULL, NULL, 2),
(61, 3, 'Ibuprofeno2', 'Ibu800', NULL, NULL, 6),
(64, 3, 'Ibuprofeno2', 'Ibu800', NULL, NULL, 2),
(66, 2, 'Ibuprofeno2', 'Actron', NULL, NULL, 3),
(67, 3, 'Ibuprofeno', 'Actron', NULL, NULL, 4),
(77, 2, 'Ibuprofeno', 'Ibuevanol', NULL, NULL, 3),
(78, 3, 'Ibuprofeno2', 'Ibu400', NULL, NULL, 3),
(79, 2, 'Aspirina', 'Ibuevanol', NULL, NULL, 3),
(80, 3, 'Ibuprofeno', 'Ibuevanol', NULL, NULL, 4),
(81, 1, 'Aspirina', 'Ibuevanol', NULL, NULL, 3),
(82, 2, 'Ibuprofeno2', 'Ibuevanol', NULL, NULL, 3),
(107, 1, 'Ibuprofeno ', 'Ibuevanol', NULL, NULL, 1);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_medicamento_recetado`
--

CREATE TABLE IF NOT EXISTS `tb_medicamento_recetado` (
  `codMedicamentoRecetado` int(11) NOT NULL,
  `codMedicamento` int(11) DEFAULT NULL,
  `cantidadDosis` int(11) DEFAULT NULL,
  `primeraDosis` datetime DEFAULT NULL,
  `intervalo` time DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_medicamento_suministrado`
--

CREATE TABLE IF NOT EXISTS `tb_medicamento_suministrado` (
  `codMedicamentoSuministrado` int(11) NOT NULL,
  `codMedicamento` int(11) DEFAULT NULL,
  `cantidadDosis` int(11) DEFAULT NULL,
  `intervalo` time DEFAULT NULL,
  `primeraDosis` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_medico`
--

CREATE TABLE IF NOT EXISTS `tb_medico` (
  `codResponsable` int(11) NOT NULL DEFAULT '0',
  `matricula` int(11) NOT NULL,
  `codEspecialidad` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_medico`
--

INSERT INTO `tb_medico` (`codResponsable`, `matricula`, `codEspecialidad`) VALUES
(19, 23451, 1),
(20, 34235, 10);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_nivel`
--

CREATE TABLE IF NOT EXISTS `tb_nivel` (
  `idNivel` int(11) NOT NULL,
  `descripcionNivel` varchar(100) DEFAULT NULL,
  `idRol` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_obrasocial`
--

CREATE TABLE IF NOT EXISTS `tb_obrasocial` (
  `codObraSocial` int(11) NOT NULL,
  `nombreOS` varchar(100) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_obrasocial`
--

INSERT INTO `tb_obrasocial` (`codObraSocial`, `nombreOS`, `usrCarga`, `fecCarga`) VALUES
(1, 'OSDE', NULL, NULL),
(2, 'Hospital Aleman', NULL, NULL),
(3, 'Medifé', NULL, NULL),
(4, 'OSEP', NULL, NULL);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_ocupacion`
--

CREATE TABLE IF NOT EXISTS `tb_ocupacion` (
  `codOcupacion` int(11) NOT NULL,
  `nombreOcupacion` varchar(100) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_ocupacion`
--

INSERT INTO `tb_ocupacion` (`codOcupacion`, `nombreOcupacion`) VALUES
(1, 'Comerciante'),
(2, 'Estudiante'),
(3, 'Petrolero'),
(4, 'Ingeniero'),
(5, 'Contador'),
(6, 'Jubilado');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_paciente`
--

CREATE TABLE IF NOT EXISTS `tb_paciente` (
  `codPaciente` int(11) NOT NULL,
  `apellidoPaciente` varchar(100) DEFAULT NULL,
  `nombrePaciente` varchar(100) DEFAULT NULL,
  `fechaNacimiento` date DEFAULT NULL,
  `codTipoDoc` int(11) DEFAULT NULL,
  `nroDoc` int(11) DEFAULT NULL,
  `codSexo` int(11) DEFAULT NULL,
  `nroAfiliadoOS` int(11) DEFAULT NULL,
  `codOcupacion` varchar(100) DEFAULT NULL,
  `direccion` varchar(100) DEFAULT NULL,
  `codLocalidad` int(11) DEFAULT NULL,
  `telefono` int(11) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codPlanOS` int(11) DEFAULT NULL,
  `email` varchar(45) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=23 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_paciente`
--

INSERT INTO `tb_paciente` (`codPaciente`, `apellidoPaciente`, `nombrePaciente`, `fechaNacimiento`, `codTipoDoc`, `nroDoc`, `codSexo`, `nroAfiliadoOS`, `codOcupacion`, `direccion`, `codLocalidad`, `telefono`, `usrCarga`, `fecCarga`, `codPlanOS`, `email`) VALUES
(18, 'Baeza', 'Aldana', '1985-11-02', 1, 32085237, 1, 1234, '2', 'Azcuenaga 188', 1, 4983256, NULL, NULL, 12, 'aldanatb@hotmail.com'),
(19, 'Martinez', 'Pablo', '1984-09-26', 1, 30456789, 2, 3456, '4', 'Jorge Newbery 378', 2, 4678905, NULL, NULL, 4, 'pablomartinez123@hotmail.com'),
(20, 'Silvestrini', 'Giulianno', '2007-01-07', 1, 47809869, 2, 8904, '2', 'Rio Gallegos 535', 1, 4985258, NULL, NULL, 13, 'giuliannos@hotmail.com'),
(21, 'Aguero', 'Mabel', '1953-03-07', 1, 10569849, 1, 7890, '5', 'Azcuenaga 188', 1, 4983256, NULL, NULL, 7, 'mabelitaa@hotmail.com'),
(22, 'Vieyra', 'Fernanda', '1985-08-28', 1, 32095895, 1, 23445, '4', 'Martinez de Rosas 123', 2, 4985678, NULL, NULL, 8, 'fernanda.vieyra@hotmail.com');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_pedido_practica_medica`
--

CREATE TABLE IF NOT EXISTS `tb_pedido_practica_medica` (
  `codPedidoPractica` int(11) NOT NULL,
  `codPracticaMedica` int(11) DEFAULT NULL,
  `observacionPM` text,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_plan_os`
--

CREATE TABLE IF NOT EXISTS `tb_plan_os` (
  `codPlanOS` int(11) NOT NULL,
  `nombrePlanOS` varchar(100) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codObraSocial` int(11) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_plan_os`
--

INSERT INTO `tb_plan_os` (`codPlanOS`, `nombrePlanOS`, `usrCarga`, `fecCarga`, `codObraSocial`) VALUES
(1, 'OSDE Neo', NULL, NULL, 1),
(2, '210', NULL, NULL, 1),
(3, '310', NULL, NULL, 1),
(4, '410', NULL, NULL, 1),
(5, '450', NULL, NULL, 1),
(6, '510', NULL, NULL, 1),
(7, 'Platinum', NULL, NULL, 3),
(8, 'Oro', NULL, NULL, 3),
(9, 'Plata', NULL, NULL, 3),
(10, 'Bronce', NULL, NULL, 3),
(11, 'A', NULL, NULL, 2),
(12, 'Joven Plus', NULL, NULL, 2),
(13, 'KinderPlan', NULL, NULL, 2),
(14, 'Classic', NULL, NULL, 2);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_practica_medica`
--

CREATE TABLE IF NOT EXISTS `tb_practica_medica` (
  `codPracticaMedica` int(11) NOT NULL,
  `nombrePM` varchar(100) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL,
  `codServicio` int(11) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=14 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_practica_medica`
--

INSERT INTO `tb_practica_medica` (`codPracticaMedica`, `nombrePM`, `usrCarga`, `fecCarga`, `codServicio`) VALUES
(2, 'Ergometría', NULL, NULL, 1),
(3, 'Ecocardiograma', NULL, NULL, 12),
(4, 'Ecografía Transvaginal', NULL, NULL, 12),
(5, 'Ecodopler', NULL, NULL, 12),
(6, 'Colposcopía', NULL, NULL, 13),
(7, 'Monitoreo Fetal', NULL, NULL, 14),
(8, 'Hematocrito', NULL, NULL, 15),
(9, 'Hemoglobina', NULL, NULL, 15),
(10, 'Glóbulos Blancos Recuento', NULL, NULL, 15),
(11, 'Glóbulos Rojos Recuento', NULL, NULL, 15),
(12, 'Electrocardiograma', NULL, NULL, 1);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_practica_medica_realizada`
--

CREATE TABLE IF NOT EXISTS `tb_practica_medica_realizada` (
  `codPracticaRealizada` int(11) NOT NULL,
  `codPracticaMedica` int(11) DEFAULT NULL,
  `diagnostiocPracticaRealizada` text,
  `fechaRealizacion` date DEFAULT NULL,
  `horaRealizacion` time DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_presentacion`
--

CREATE TABLE IF NOT EXISTS `tb_presentacion` (
  `codPresentacion` int(11) NOT NULL,
  `descripcionPresentacion` varchar(100) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_presentacion`
--

INSERT INTO `tb_presentacion` (`codPresentacion`, `descripcionPresentacion`) VALUES
(1, 'Cápsulas'),
(2, 'Comprimidos'),
(3, 'Pomada'),
(4, 'Inyectable'),
(5, 'Gotas'),
(6, 'Jarabe'),
(7, 'Inhalador Bucal'),
(8, 'Inhalador Nasal'),
(9, 'Supositorios'),
(10, 'Colirios');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_provincia`
--

CREATE TABLE IF NOT EXISTS `tb_provincia` (
  `codProvincia` int(11) NOT NULL,
  `nombreProvincia` varchar(100) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_provincia`
--

INSERT INTO `tb_provincia` (`codProvincia`, `nombreProvincia`) VALUES
(1, 'Mendoza'),
(2, 'Córdoba');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_responsable`
--

CREATE TABLE IF NOT EXISTS `tb_responsable` (
  `codResponsable` int(11) NOT NULL,
  `apellidoR` varchar(100) DEFAULT NULL,
  `nombreR` varchar(100) DEFAULT NULL,
  `direccionR` varchar(45) NOT NULL,
  `telefonoR` int(11) NOT NULL,
  `dniR` int(11) NOT NULL,
  `tipoResponsable` varchar(45) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=23 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_responsable`
--

INSERT INTO `tb_responsable` (`codResponsable`, `apellidoR`, `nombreR`, `direccionR`, `telefonoR`, `dniR`, `tipoResponsable`) VALUES
(19, 'Cicconi', 'Gisella', 'Belgrano 284', 4398725, 32098478, 'Médico'),
(20, 'Zanon', 'Karina', 'Francia 231', 4582945, 31835920, 'Médico'),
(21, 'Herrera', 'Celeste', 'San Martin 284', 4982748, 32089473, 'Enfermero'),
(22, 'Molina', 'Natalia', 'Lares 398', 4782946, 34893094, 'Enfermero');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_rol`
--

CREATE TABLE IF NOT EXISTS `tb_rol` (
  `idRol` int(11) NOT NULL,
  `descripcionRol` varchar(100) DEFAULT NULL,
  `idUsuario` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_servicio`
--

CREATE TABLE IF NOT EXISTS `tb_servicio` (
  `codServicio` int(11) NOT NULL,
  `nombreServicio` varchar(45) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_servicio`
--

INSERT INTO `tb_servicio` (`codServicio`, `nombreServicio`) VALUES
(1, 'Cardiología'),
(2, 'Maternidad'),
(3, 'Terapia Intensiva'),
(4, 'Terapia Intermedia'),
(5, 'Traumatología'),
(7, 'Urología'),
(8, 'Oncología'),
(9, 'Infectología'),
(10, 'Pediatría'),
(11, 'Cirugía'),
(12, 'Ecografía'),
(13, 'Ginecología'),
(14, 'Obstetricia'),
(15, 'Hematología ');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_sexo`
--

CREATE TABLE IF NOT EXISTS `tb_sexo` (
  `codSexo` int(11) NOT NULL,
  `nombreSexo` varchar(100) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_sexo`
--

INSERT INTO `tb_sexo` (`codSexo`, `nombreSexo`) VALUES
(1, 'Femenino'),
(2, 'Masculino');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_tiposdoc`
--

CREATE TABLE IF NOT EXISTS `tb_tiposdoc` (
  `codTipoDoc` int(11) NOT NULL,
  `tipoDoc` varchar(100) DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_tiposdoc`
--

INSERT INTO `tb_tiposdoc` (`codTipoDoc`, `tipoDoc`) VALUES
(1, 'D.U.'),
(2, 'L.C.'),
(3, 'L.E.');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_tipo_alta`
--

CREATE TABLE IF NOT EXISTS `tb_tipo_alta` (
  `codTipoAlta` int(11) NOT NULL,
  `descripcionTipoAlta` varchar(50) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_tipo_detalle_internacion`
--

CREATE TABLE IF NOT EXISTS `tb_tipo_detalle_internacion` (
  `codTipoDI` int(11) NOT NULL,
  `descripcionTipoDI` varchar(100) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_tratamiento`
--

CREATE TABLE IF NOT EXISTS `tb_tratamiento` (
  `codTratamiento` int(11) NOT NULL,
  `nombreTratamiento` varchar(45) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=20 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_tratamiento`
--

INSERT INTO `tb_tratamiento` (`codTratamiento`, `nombreTratamiento`) VALUES
(1, 'Acupuntura'),
(2, 'Cirugía'),
(3, 'Dieta'),
(4, 'Farmacoterapia'),
(5, 'Fisioterapia'),
(6, 'Fitoterapia'),
(7, 'Hidroterapia'),
(8, 'Ortopedia'),
(9, 'Prótesis'),
(10, 'Psicoterapia'),
(11, 'Quimioterapia'),
(12, 'Radioterapia'),
(13, 'Rehabilitacion'),
(14, 'Reposo'),
(15, 'Sueroterapia'),
(18, 'Tratamiento de Quelación'),
(19, 'Terapia Ocupacional');

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_usuario`
--

CREATE TABLE IF NOT EXISTS `tb_usuario` (
  `idUsuario` int(11) NOT NULL,
  `nombreUsuario` varchar(45) DEFAULT NULL,
  `apellidoUsuario` varchar(45) DEFAULT NULL,
  `contrasenia` varchar(100) DEFAULT NULL,
  `documentoUsuario` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_via_administracion`
--

CREATE TABLE IF NOT EXISTS `tb_via_administracion` (
  `codViaAdministracion` int(11) NOT NULL,
  `descripcionVia` varchar(100) DEFAULT NULL,
  `usrCarga` varchar(30) DEFAULT NULL,
  `fecCarga` datetime DEFAULT NULL
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=latin1;

--
-- Volcado de datos para la tabla `tb_via_administracion`
--

INSERT INTO `tb_via_administracion` (`codViaAdministracion`, `descripcionVia`, `usrCarga`, `fecCarga`) VALUES
(1, 'Oral', NULL, NULL),
(2, 'Intravenosa', NULL, NULL),
(3, 'Intramuscular', NULL, NULL),
(4, 'Tópica', NULL, NULL),
(5, 'Subcutánea', NULL, NULL);

-- --------------------------------------------------------

--
-- Estructura de tabla para la tabla `tb_visibilidad`
--

CREATE TABLE IF NOT EXISTS `tb_visibilidad` (
  `idVisibilidad` int(11) NOT NULL,
  `descripcionVisibilidad` varchar(100) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Índices para tablas volcadas
--

--
-- Indices de la tabla `tb_acceso`
--
ALTER TABLE `tb_acceso`
  ADD PRIMARY KEY (`idAcceso`);

--
-- Indices de la tabla `tb_atencion_basica`
--
ALTER TABLE `tb_atencion_basica`
  ADD PRIMARY KEY (`codAtencionBasica`);

--
-- Indices de la tabla `tb_cama`
--
ALTER TABLE `tb_cama`
  ADD PRIMARY KEY (`nroCama`), ADD KEY `idEstadoCama_idx` (`idEstadoCama`), ADD KEY `codHabitacion_idx` (`codHabitacion`);

--
-- Indices de la tabla `tb_condicion_alta`
--
ALTER TABLE `tb_condicion_alta`
  ADD PRIMARY KEY (`codCondicionAlta`);

--
-- Indices de la tabla `tb_enfermedad`
--
ALTER TABLE `tb_enfermedad`
  ADD PRIMARY KEY (`codEnfermedad`);

--
-- Indices de la tabla `tb_enfermero`
--
ALTER TABLE `tb_enfermero`
  ADD PRIMARY KEY (`codResponsable`), ADD KEY `codServicio` (`codServicio`);

--
-- Indices de la tabla `tb_especialidad`
--
ALTER TABLE `tb_especialidad`
  ADD PRIMARY KEY (`codEspecialidad`);

--
-- Indices de la tabla `tb_estado_cama`
--
ALTER TABLE `tb_estado_cama`
  ADD PRIMARY KEY (`idEstadoCama`);

--
-- Indices de la tabla `tb_estado_etiqueta_rfid`
--
ALTER TABLE `tb_estado_etiqueta_rfid`
  ADD PRIMARY KEY (`codEstadoEtiqueta`);

--
-- Indices de la tabla `tb_etiqueta_rfid`
--
ALTER TABLE `tb_etiqueta_rfid`
  ADD PRIMARY KEY (`nroEtiqueta`), ADD KEY `codEstadoEtiqueta` (`codEstadoEtiqueta`);

--
-- Indices de la tabla `tb_funcionalidad`
--
ALTER TABLE `tb_funcionalidad`
  ADD PRIMARY KEY (`idFuncionalidad`);

--
-- Indices de la tabla `tb_habitacion`
--
ALTER TABLE `tb_habitacion`
  ADD PRIMARY KEY (`codHabitacion`);

--
-- Indices de la tabla `tb_historia_clinica_internacion`
--
ALTER TABLE `tb_historia_clinica_internacion`
  ADD PRIMARY KEY (`nroHCI`);

--
-- Indices de la tabla `tb_indicacion`
--
ALTER TABLE `tb_indicacion`
  ADD PRIMARY KEY (`codIndicacion`);

--
-- Indices de la tabla `tb_indicacion_recetada`
--
ALTER TABLE `tb_indicacion_recetada`
  ADD PRIMARY KEY (`codIndicacionRecetada`);

--
-- Indices de la tabla `tb_internacion`
--
ALTER TABLE `tb_internacion`
  ADD PRIMARY KEY (`nroInternación`), ADD KEY `nroHCI` (`nroHCI`), ADD KEY `codCondicionAlta_idx` (`codCondicionAlta`), ADD KEY `codTratamiento_idx` (`codTratamiento`), ADD KEY `nroCama_idx` (`nroCama`);

--
-- Indices de la tabla `tb_internacion_detalle`
--
ALTER TABLE `tb_internacion_detalle`
  ADD PRIMARY KEY (`nroDetalleInternacion`), ADD KEY `nroInternacion` (`nroInternacion`), ADD KEY `codTipoDI_idx` (`codTipoDI`);

--
-- Indices de la tabla `tb_lista_accesos`
--
ALTER TABLE `tb_lista_accesos`
  ADD PRIMARY KEY (`idListaAccesos`), ADD KEY `idAcceso_idx` (`idAcceso`), ADD KEY `idNivel_idx` (`idNivel`);

--
-- Indices de la tabla `tb_lista_funcionalidades`
--
ALTER TABLE `tb_lista_funcionalidades`
  ADD PRIMARY KEY (`idListaFuncionalidades`), ADD KEY `idFuncionalidad_idx` (`idFuncionalidad`), ADD KEY `idNivel_idx` (`idNivel`);

--
-- Indices de la tabla `tb_lista_visibilidades`
--
ALTER TABLE `tb_lista_visibilidades`
  ADD PRIMARY KEY (`idListaVisibilidades`), ADD KEY `idVisibilidad_idx` (`idVisibilidad`), ADD KEY `idNivel_idx` (`idNivel`);

--
-- Indices de la tabla `tb_localidad`
--
ALTER TABLE `tb_localidad`
  ADD PRIMARY KEY (`codLocalidad`);

--
-- Indices de la tabla `tb_medicamento`
--
ALTER TABLE `tb_medicamento`
  ADD PRIMARY KEY (`codMedicamento`), ADD KEY `codViaAdministracion_idx` (`codViaAdministracion`), ADD KEY `codPresentacion_idx` (`codPresentacion`);

--
-- Indices de la tabla `tb_medicamento_recetado`
--
ALTER TABLE `tb_medicamento_recetado`
  ADD PRIMARY KEY (`codMedicamentoRecetado`);

--
-- Indices de la tabla `tb_medicamento_suministrado`
--
ALTER TABLE `tb_medicamento_suministrado`
  ADD PRIMARY KEY (`codMedicamentoSuministrado`);

--
-- Indices de la tabla `tb_medico`
--
ALTER TABLE `tb_medico`
  ADD PRIMARY KEY (`codResponsable`), ADD KEY `codResponsable` (`codResponsable`), ADD KEY `codEspecialidad` (`codEspecialidad`);

--
-- Indices de la tabla `tb_nivel`
--
ALTER TABLE `tb_nivel`
  ADD PRIMARY KEY (`idNivel`), ADD KEY `idRol_idx` (`idRol`);

--
-- Indices de la tabla `tb_obrasocial`
--
ALTER TABLE `tb_obrasocial`
  ADD PRIMARY KEY (`codObraSocial`);

--
-- Indices de la tabla `tb_ocupacion`
--
ALTER TABLE `tb_ocupacion`
  ADD PRIMARY KEY (`codOcupacion`);

--
-- Indices de la tabla `tb_paciente`
--
ALTER TABLE `tb_paciente`
  ADD PRIMARY KEY (`codPaciente`), ADD KEY `codPlanOS` (`codPlanOS`);

--
-- Indices de la tabla `tb_pedido_practica_medica`
--
ALTER TABLE `tb_pedido_practica_medica`
  ADD PRIMARY KEY (`codPedidoPractica`);

--
-- Indices de la tabla `tb_plan_os`
--
ALTER TABLE `tb_plan_os`
  ADD PRIMARY KEY (`codPlanOS`);

--
-- Indices de la tabla `tb_practica_medica`
--
ALTER TABLE `tb_practica_medica`
  ADD PRIMARY KEY (`codPracticaMedica`), ADD KEY `codServicio_idx` (`codServicio`);

--
-- Indices de la tabla `tb_practica_medica_realizada`
--
ALTER TABLE `tb_practica_medica_realizada`
  ADD PRIMARY KEY (`codPracticaRealizada`);

--
-- Indices de la tabla `tb_presentacion`
--
ALTER TABLE `tb_presentacion`
  ADD PRIMARY KEY (`codPresentacion`);

--
-- Indices de la tabla `tb_provincia`
--
ALTER TABLE `tb_provincia`
  ADD PRIMARY KEY (`codProvincia`);

--
-- Indices de la tabla `tb_responsable`
--
ALTER TABLE `tb_responsable`
  ADD PRIMARY KEY (`codResponsable`);

--
-- Indices de la tabla `tb_rol`
--
ALTER TABLE `tb_rol`
  ADD PRIMARY KEY (`idRol`), ADD KEY `idUsuario_idx` (`idUsuario`);

--
-- Indices de la tabla `tb_servicio`
--
ALTER TABLE `tb_servicio`
  ADD PRIMARY KEY (`codServicio`);

--
-- Indices de la tabla `tb_sexo`
--
ALTER TABLE `tb_sexo`
  ADD PRIMARY KEY (`codSexo`);

--
-- Indices de la tabla `tb_tiposdoc`
--
ALTER TABLE `tb_tiposdoc`
  ADD PRIMARY KEY (`codTipoDoc`);

--
-- Indices de la tabla `tb_tipo_alta`
--
ALTER TABLE `tb_tipo_alta`
  ADD PRIMARY KEY (`codTipoAlta`);

--
-- Indices de la tabla `tb_tipo_detalle_internacion`
--
ALTER TABLE `tb_tipo_detalle_internacion`
  ADD PRIMARY KEY (`codTipoDI`);

--
-- Indices de la tabla `tb_tratamiento`
--
ALTER TABLE `tb_tratamiento`
  ADD PRIMARY KEY (`codTratamiento`);

--
-- Indices de la tabla `tb_usuario`
--
ALTER TABLE `tb_usuario`
  ADD PRIMARY KEY (`idUsuario`);

--
-- Indices de la tabla `tb_via_administracion`
--
ALTER TABLE `tb_via_administracion`
  ADD PRIMARY KEY (`codViaAdministracion`);

--
-- Indices de la tabla `tb_visibilidad`
--
ALTER TABLE `tb_visibilidad`
  ADD PRIMARY KEY (`idVisibilidad`);

--
-- AUTO_INCREMENT de las tablas volcadas
--

--
-- AUTO_INCREMENT de la tabla `tb_acceso`
--
ALTER TABLE `tb_acceso`
  MODIFY `idAcceso` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_atencion_basica`
--
ALTER TABLE `tb_atencion_basica`
  MODIFY `codAtencionBasica` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_cama`
--
ALTER TABLE `tb_cama`
  MODIFY `nroCama` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6;
--
-- AUTO_INCREMENT de la tabla `tb_condicion_alta`
--
ALTER TABLE `tb_condicion_alta`
  MODIFY `codCondicionAlta` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_enfermedad`
--
ALTER TABLE `tb_enfermedad`
  MODIFY `codEnfermedad` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=47;
--
-- AUTO_INCREMENT de la tabla `tb_especialidad`
--
ALTER TABLE `tb_especialidad`
  MODIFY `codEspecialidad` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
--
-- AUTO_INCREMENT de la tabla `tb_estado_cama`
--
ALTER TABLE `tb_estado_cama`
  MODIFY `idEstadoCama` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
--
-- AUTO_INCREMENT de la tabla `tb_estado_etiqueta_rfid`
--
ALTER TABLE `tb_estado_etiqueta_rfid`
  MODIFY `codEstadoEtiqueta` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
--
-- AUTO_INCREMENT de la tabla `tb_etiqueta_rfid`
--
ALTER TABLE `tb_etiqueta_rfid`
  MODIFY `nroEtiqueta` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
--
-- AUTO_INCREMENT de la tabla `tb_funcionalidad`
--
ALTER TABLE `tb_funcionalidad`
  MODIFY `idFuncionalidad` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_habitacion`
--
ALTER TABLE `tb_habitacion`
  MODIFY `codHabitacion` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=7;
--
-- AUTO_INCREMENT de la tabla `tb_historia_clinica_internacion`
--
ALTER TABLE `tb_historia_clinica_internacion`
  MODIFY `nroHCI` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=7;
--
-- AUTO_INCREMENT de la tabla `tb_indicacion`
--
ALTER TABLE `tb_indicacion`
  MODIFY `codIndicacion` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_indicacion_recetada`
--
ALTER TABLE `tb_indicacion_recetada`
  MODIFY `codIndicacionRecetada` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_internacion`
--
ALTER TABLE `tb_internacion`
  MODIFY `nroInternación` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_internacion_detalle`
--
ALTER TABLE `tb_internacion_detalle`
  MODIFY `nroDetalleInternacion` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_lista_accesos`
--
ALTER TABLE `tb_lista_accesos`
  MODIFY `idListaAccesos` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_lista_visibilidades`
--
ALTER TABLE `tb_lista_visibilidades`
  MODIFY `idListaVisibilidades` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_localidad`
--
ALTER TABLE `tb_localidad`
  MODIFY `codLocalidad` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
--
-- AUTO_INCREMENT de la tabla `tb_medicamento`
--
ALTER TABLE `tb_medicamento`
  MODIFY `codMedicamento` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=110;
--
-- AUTO_INCREMENT de la tabla `tb_medicamento_recetado`
--
ALTER TABLE `tb_medicamento_recetado`
  MODIFY `codMedicamentoRecetado` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_medicamento_suministrado`
--
ALTER TABLE `tb_medicamento_suministrado`
  MODIFY `codMedicamentoSuministrado` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_nivel`
--
ALTER TABLE `tb_nivel`
  MODIFY `idNivel` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_obrasocial`
--
ALTER TABLE `tb_obrasocial`
  MODIFY `codObraSocial` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6;
--
-- AUTO_INCREMENT de la tabla `tb_ocupacion`
--
ALTER TABLE `tb_ocupacion`
  MODIFY `codOcupacion` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=7;
--
-- AUTO_INCREMENT de la tabla `tb_paciente`
--
ALTER TABLE `tb_paciente`
  MODIFY `codPaciente` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=23;
--
-- AUTO_INCREMENT de la tabla `tb_pedido_practica_medica`
--
ALTER TABLE `tb_pedido_practica_medica`
  MODIFY `codPedidoPractica` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_plan_os`
--
ALTER TABLE `tb_plan_os`
  MODIFY `codPlanOS` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=16;
--
-- AUTO_INCREMENT de la tabla `tb_practica_medica`
--
ALTER TABLE `tb_practica_medica`
  MODIFY `codPracticaMedica` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=14;
--
-- AUTO_INCREMENT de la tabla `tb_practica_medica_realizada`
--
ALTER TABLE `tb_practica_medica_realizada`
  MODIFY `codPracticaRealizada` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_presentacion`
--
ALTER TABLE `tb_presentacion`
  MODIFY `codPresentacion` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
--
-- AUTO_INCREMENT de la tabla `tb_provincia`
--
ALTER TABLE `tb_provincia`
  MODIFY `codProvincia` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT de la tabla `tb_responsable`
--
ALTER TABLE `tb_responsable`
  MODIFY `codResponsable` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=23;
--
-- AUTO_INCREMENT de la tabla `tb_rol`
--
ALTER TABLE `tb_rol`
  MODIFY `idRol` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_servicio`
--
ALTER TABLE `tb_servicio`
  MODIFY `codServicio` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=16;
--
-- AUTO_INCREMENT de la tabla `tb_sexo`
--
ALTER TABLE `tb_sexo`
  MODIFY `codSexo` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT de la tabla `tb_tiposdoc`
--
ALTER TABLE `tb_tiposdoc`
  MODIFY `codTipoDoc` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
--
-- AUTO_INCREMENT de la tabla `tb_tipo_alta`
--
ALTER TABLE `tb_tipo_alta`
  MODIFY `codTipoAlta` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_tipo_detalle_internacion`
--
ALTER TABLE `tb_tipo_detalle_internacion`
  MODIFY `codTipoDI` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_tratamiento`
--
ALTER TABLE `tb_tratamiento`
  MODIFY `codTratamiento` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=20;
--
-- AUTO_INCREMENT de la tabla `tb_usuario`
--
ALTER TABLE `tb_usuario`
  MODIFY `idUsuario` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT de la tabla `tb_via_administracion`
--
ALTER TABLE `tb_via_administracion`
  MODIFY `codViaAdministracion` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6;
--
-- AUTO_INCREMENT de la tabla `tb_visibilidad`
--
ALTER TABLE `tb_visibilidad`
  MODIFY `idVisibilidad` int(11) NOT NULL AUTO_INCREMENT;
--
-- Restricciones para tablas volcadas
--

--
-- Filtros para la tabla `tb_cama`
--
ALTER TABLE `tb_cama`
ADD CONSTRAINT `codHabitacion` FOREIGN KEY (`codHabitacion`) REFERENCES `tb_habitacion` (`codHabitacion`) ON DELETE NO ACTION ON UPDATE NO ACTION,
ADD CONSTRAINT `idEstadoCama` FOREIGN KEY (`idEstadoCama`) REFERENCES `tb_estado_cama` (`idEstadoCama`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_enfermero`
--
ALTER TABLE `tb_enfermero`
ADD CONSTRAINT `tb_enfermero_ibfk_1` FOREIGN KEY (`codResponsable`) REFERENCES `tb_responsable` (`codResponsable`),
ADD CONSTRAINT `tb_enfermero_ibfk_2` FOREIGN KEY (`codServicio`) REFERENCES `tb_servicio` (`codServicio`);

--
-- Filtros para la tabla `tb_etiqueta_rfid`
--
ALTER TABLE `tb_etiqueta_rfid`
ADD CONSTRAINT `tb_etiqueta_rfid_ibfk_1` FOREIGN KEY (`codEstadoEtiqueta`) REFERENCES `tb_estado_etiqueta_rfid` (`codEstadoEtiqueta`);

--
-- Filtros para la tabla `tb_internacion`
--
ALTER TABLE `tb_internacion`
ADD CONSTRAINT `codCondicionAlta` FOREIGN KEY (`codCondicionAlta`) REFERENCES `tb_condicion_alta` (`codCondicionAlta`) ON DELETE NO ACTION ON UPDATE NO ACTION,
ADD CONSTRAINT `codTratamiento` FOREIGN KEY (`codTratamiento`) REFERENCES `tb_tratamiento` (`codTratamiento`) ON DELETE NO ACTION ON UPDATE NO ACTION,
ADD CONSTRAINT `nroCama` FOREIGN KEY (`nroCama`) REFERENCES `tb_cama` (`nroCama`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_lista_accesos`
--
ALTER TABLE `tb_lista_accesos`
ADD CONSTRAINT `idAcceso` FOREIGN KEY (`idAcceso`) REFERENCES `tb_acceso` (`idAcceso`) ON DELETE NO ACTION ON UPDATE NO ACTION,
ADD CONSTRAINT `idNivel` FOREIGN KEY (`idNivel`) REFERENCES `tb_nivel` (`idNivel`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_lista_funcionalidades`
--
ALTER TABLE `tb_lista_funcionalidades`
ADD CONSTRAINT `idFuncionalidad` FOREIGN KEY (`idFuncionalidad`) REFERENCES `tb_funcionalidad` (`idFuncionalidad`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_lista_visibilidades`
--
ALTER TABLE `tb_lista_visibilidades`
ADD CONSTRAINT `idVisibilidad` FOREIGN KEY (`idVisibilidad`) REFERENCES `tb_visibilidad` (`idVisibilidad`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_medicamento`
--
ALTER TABLE `tb_medicamento`
ADD CONSTRAINT `codPresentacion` FOREIGN KEY (`codPresentacion`) REFERENCES `tb_presentacion` (`codPresentacion`) ON DELETE NO ACTION ON UPDATE NO ACTION,
ADD CONSTRAINT `codViaAdministracion` FOREIGN KEY (`codViaAdministracion`) REFERENCES `tb_via_administracion` (`codViaAdministracion`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_medico`
--
ALTER TABLE `tb_medico`
ADD CONSTRAINT `tb_medico_ibfk_1` FOREIGN KEY (`codResponsable`) REFERENCES `tb_responsable` (`codResponsable`),
ADD CONSTRAINT `tb_medico_ibfk_2` FOREIGN KEY (`codEspecialidad`) REFERENCES `tb_especialidad` (`codEspecialidad`);

--
-- Filtros para la tabla `tb_nivel`
--
ALTER TABLE `tb_nivel`
ADD CONSTRAINT `idRol` FOREIGN KEY (`idRol`) REFERENCES `tb_rol` (`idRol`) ON DELETE NO ACTION ON UPDATE NO ACTION;

--
-- Filtros para la tabla `tb_paciente`
--
ALTER TABLE `tb_paciente`
ADD CONSTRAINT `tb_paciente_ibfk_1` FOREIGN KEY (`codPlanOS`) REFERENCES `tb_plan_os` (`codPlanOS`);

--
-- Filtros para la tabla `tb_rol`
--
ALTER TABLE `tb_rol`
ADD CONSTRAINT `idUsuario` FOREIGN KEY (`idUsuario`) REFERENCES `tb_usuario` (`idUsuario`) ON DELETE NO ACTION ON UPDATE NO ACTION;

/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;


text:
This little project aims to solve the following problems:

1. Make stuff more awesome.
2. Remove the less awesome stuff from your project.

## Configuration

Add the Sonatype.org Releases repo as a resolver in your `build.sbt` or `Build.scala` as appropriate.

```scala
resolvers += "Sonatype.org Releases" at "https://oss.sonatype.org/content/repositories/releases/"
```

Add **$name$** as a dependency in your `build.sbt` or `Build.scala` as appropriate.

```scala
libraryDependencies ++= Seq(
  // Other dependencies ...
  "$organization;format="lower"$" %% "$name;format="word"$" % "0.0.1" % "compile"
)
```

## Scala Versions

This project is compiled, tested, and published for the following Scala versions:

1. 2.9.1
2. 2.9.1-1
3. 2.9.2
4. 2.9.3
5. 2.10.3

## Usage

To use **$name$**, you should import it and call it...

## Scaladoc API

The Scaladoc API for this project can be found [here](http://$github_id$.github.io/$name;format="norm"$/latest/api).

## Examples

```scala
package org.example

import $package$._

case object MyObject {
  // ...
}
```

## Wishlist

Below is a list of features we would like to one day include in this project

1. Support more awesome.
2. Decimate the not-awesome.

## License

*$name$* is licensed under [APL 2.0](http://www.apache.org/licenses/LICENSE-2.0).

Copyright 2013 $organization$

   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.

redpajama_set_name: RedPajamaGithub


text:
/*
 * Do not modify this file. This file is generated from the cloudsearch-2013-01-01.normal.json service model.
 */
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;

using Amazon.Runtime;
using Amazon.Runtime.Internal;

namespace Amazon.CloudSearch.Model
{
    ///
    /// The result of a UpdateAvailabilityOptions request. Contains the status
    /// of the domain's availability options.
    ///
    public partial class UpdateAvailabilityOptionsResponse : AmazonWebServiceResponse
    {
        private AvailabilityOptionsStatus _availabilityOptions;

        ///
        /// Gets and sets the property AvailabilityOptions.
        /// <para>
        /// The newly-configured availability options. Indicates whether Multi-AZ is enabled for
        /// the domain.
        /// </para>
        ///
        public AvailabilityOptionsStatus AvailabilityOptions
        {
            get { return this._availabilityOptions; }
            set { this._availabilityOptions = value; }
        }

        // Check to see if AvailabilityOptions property is set
        internal bool IsSetAvailabilityOptions()
        {
            return this._availabilityOptions != null;
        }

    }
}


text:
require 'ostruct'

require 'tournament_system'

class TestDriver < TournamentSystem::Driver
  # rubocop:disable Metrics/CyclomaticComplexity
  def initialize(options = {})
    @teams = options[:teams] || []
    @ranked_teams = options[:ranked_teams] || @teams
    @matches = options[:matches] || []
    @winners = options[:winners] || {}
    @scores = options[:scores] || Hash.new(0)
    @team_matches = options[:team_matches] || build_team_matches_from_matches
    @created_matches = []
  end
  # rubocop:enable Metrics/CyclomaticComplexity

  attr_accessor :scores
  attr_accessor :teams
  attr_accessor :ranked_teams
  attr_accessor :matches
  attr_accessor :created_matches

  def seeded_teams
    @teams
  end

  def get_match_teams(match)
    match
  end

  def get_match_winner(match)
    @winners[match]
  end

  def get_team_score(team)
    @scores[team]
  end

  def get_team_matches(team)
    @team_matches[team]
  end

  def build_match(home_team, away_team)
    @created_matches << OpenStruct.new(home_team: home_team,
                                       away_team: away_team)
  end

  private

  def build_team_matches_from_matches
    result = {}
    @teams.each { |team| result[team] = [] }

    @matches.each do |match|
      match.reject(&:nil?).each do |team|
        result[team] << match if result.include?(team)
      end
    end

    result
  end
end


text:
if(!dojo._hasResource["dojox.data.tests.stores.JsonRestStore"]){ //_hasResource checks added by build. Do not use _hasResource directly in your code.
dojo._hasResource["dojox.data.tests.stores.JsonRestStore"] = true;
dojo.provide("dojox.data.tests.stores.JsonRestStore");
dojo.require("dojox.rpc.Service");
//dojo.require("dojox.data.ClientFilter");
dojo.require("dojox.data.JsonRestStore");
dojo.require("dojox.json.schema");
dojo.require("dojo.data.api.Read");

dojox.data.tests.stores.JsonRestStore.error = function(t, d, errData){
	//  summary:
	//		The error callback function to be used for all of the tests.
	d.errback(errData);
}
testServices = new dojox.rpc.Service(dojo.moduleUrl("dojox.rpc.tests.resources", "test.smd"));
testServices.jsonRestStore.servicePath = "/jsonRest.Store/"; // this makes the regex more challenging
jsonStore = new dojox.data.JsonRestStore({service:testServices.jsonRestStore});

doh.register("dojox.data.tests.stores.JsonRestStore",
	[
		{
			name: "Fetch some items",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		Simple test of a basic fetch on JsonRestStore of a simple query.
				var d = new doh.Deferred();
				jsonStore.fetch({query:"query",
					onComplete: function(items, request){
						t.is(4, items.length);
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "fetch by id",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		Simple test of a basic fetch on JsonRestStore of a single item.
				var d = new doh.Deferred();
				jsonStore.fetch({query:"obj1",
					onComplete: function(item, request){
						t.is("Object 1", item.name);
						t.t(jsonStore.hasAttribute(item,"name"));
						t.is(jsonStore.getValues(item,"name").length,1);
						t.t(jsonStore.isItem(item));
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "Modify,save, check by id",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		Fetch an item from a query, modify and save it, and check to see if it was modified correctly
				var d = new doh.Deferred();
				jsonStore.fetch({query:"query",
					onComplete: function(items, request){
						var now = new Date().getTime();
						jsonStore.setValue(items[0],"updated",now);
						jsonStore.setValue(items[0],"obj",{foo:'bar'});
						jsonStore.setValue(items[0],"obj dup",items[0].obj);
						jsonStore.setValue(items[0],"testArray",[1,2,3,4]);
						jsonStore.save({onComplete:function(){
							jsonStore.fetchItemByIdentity({identity:"obj1",
								onItem: function(item, request){
									t.is("Object 1", item.name);
									t.is(now, item.updated);
									t.is("bar", item.obj.foo);
									t.is(item.obj, item['obj dup']);
									d.callback(true);
								},
								onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
							});
						}});
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "Revert",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		append/post an item, delete it, sort the lists, resort the list, saving each time.
				var d = new doh.Deferred();
				jsonStore.fetch({query:"obj1",
					onComplete: function(item, request){
						jsonStore.setValue(item,"name","new name");
						jsonStore.setValue(item,"newProp","new value");
						jsonStore.unsetAttribute(item,"updated");
						t.is(jsonStore.getValue(item,"name"),"new name");
						t.is(jsonStore.getValue(item,"newProp"),"new value");
						t.is(jsonStore.getValue(item,"updated"),undefined);
						jsonStore.revert();
						t.is(jsonStore.getValue(item,"name"),"Object 1");
						t.is(jsonStore.getValue(item,"newProp"),undefined);
						t.t(typeof jsonStore.getValue(item,"updated") == 'number');
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "Delete",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		append/post an item, delete it, sort the lists, resort the list, saving each time.
				var d = new doh.Deferred();
				jsonStore.fetchItemByIdentity({identity:"obj1",
					onItem: function(item, request){
						var newItem = jsonStore.newItem({directRef: item});
						jsonStore.setValue(newItem, "arrayRef", [1,{subobject:item},item]);
						jsonStore.deleteItem(item);
						t.is(jsonStore.getValue(newItem, "directRef"), undefined);
						t.is(jsonStore.getValue(newItem, "arrayRef").length, 2);
						t.is(jsonStore.getValue(newItem, "arrayRef")[1].subobject, undefined);
						jsonStore.revert();
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "Lazy loading",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		test lazy loading
				var d = new doh.Deferred();
				jsonStore.fetch({query:"query",
					onComplete: function(items, request){
						var item = items[2];
						t.f(jsonStore.isItemLoaded(item));
						jsonStore.getValue(item,"name"); // this should trigger the load
						t.is(items[2],item);
						t.is(item.name,'Object 3');
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		{
			name: "Lazy loading 2",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		test lazy loading
				var d = new doh.Deferred();
				jsonStore.fetch({query:"query",
					onComplete: function(items, request){
						t.f(jsonStore.isItemLoaded(items[3]));
						jsonStore.loadItem({item:items[3],onItem:function(item){
							t.t(jsonStore.isItemLoaded(items[3]));
							t.is(item,items[3]);
							t.is(item.name,'Object 4');
							d.callback(true);
						}});

					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},
		/*{
			name: "Load Lazy Value",
			timeout:	10000, //10 seconds.
			runTest: function(t) {
				//	summary:
				//		Simple test of a basic fetch on ServiceStore of a single item.
				var d = new doh.Deferred();
				jsonStore.fetchItemByIdentity({identity:"obj1",
					onItem: function(item, request){
						t.is("Object 1", item.name);
						t.f(jsonStore.isItemLoaded(item.lazyValue));
						var lazyValue = jsonStore.getValue(item,"lazyValue");
						t.is("Finally loaded",lazyValue);
						lazyValue = jsonStore.getValue(item,"lazyValue");
						d.callback(true);
					},
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, doh, d)
				});
				return d; //Object
			}
		},*/

		{
			name: "IdentityAPI: fetchItemByIdentity and getIdentity",
			timeout: 30000,
			runTest: function(t) {
				//	summary:
				//		Verify the fetchItemByIdentity method works
				var d = new doh.Deferred();

				jsonStore.fetchItemByIdentity({identity:"obj3",
					onItem: function(item, request){
						t.t(jsonStore.isItemLoaded(item));
						t.is(jsonStore.getIdentity(item),"obj3");
					}
				});
			}
		},

		{
			name: "ReadAPI:  Fetch_20_Streaming",
			timeout:	10000, //10 seconds.  Json can sometimes be slow.
			runTest: function(t) {
				//	summary:
				//		fetching with paging

				var d = new doh.Deferred();
				var count = 0;

				function onItem(item, requestObj){
				  t.assertTrue(typeof item == 'number');
				  count++;
				}
				function onComplete(items, request){
					t.is(20, count);

					d.callback(true);
				}
				//Get everything...
				jsonStore.fetch({
					query: "bigQuery",
					onBegin: null,
					count: 20,
					onItem: onItem,
					onComplete: onComplete,
					onError: dojo.partial(dojox.data.tests.stores.JsonRestStore.error, t, d)
				});
				return d; //Object
			}
		},
		function testSchema(t){
			var d = new doh.Deferred();
			jsonStore.fetchItemByIdentity({identity:"obj3",
				onItem: function(item, request){
					var set = false;
					try{
						jsonStore.setValue(item,"name",333); // should only take a string, so it should throw an exception
						set = true;
					}catch(e){
						console.log("Correctly blocked invalid property change by schema:",e);
					}
					try{
						jsonStore.setValue(item,"name","a"); // should be at least three character, so it should throw an execption
						set = true;
					}catch(e){
						console.log("Correctly blocked invalid property change by schema:",e);
					}
					t.f(set);
					d.callback(true);
				}
			});

		},
		function testReadAPI_functionConformance(t){
			//	summary:
			//		Simple test read API conformance.  Checks to see all declared functions are actual functions on the instances.
			//	description:
			//		Simple test read API conformance.  Checks to see all declared functions are actual functions on the instances.

			var readApi = new dojo.data.api.Read();
			var passed = true;

			for(i in readApi){
				if(i.toString().charAt(0) !== '_')
				{
					var member = readApi[i];
					//Check that all the 'Read' defined functions exist on the test store.
					if(typeof member === "function"){
						var testStoreMember = jsonStore	[i];
						if(!(typeof testStoreMember === "function")){
							passed = false;
							break;
						}
					}
				}
			}
		}
	]
);
performanceTest = function (){
	dojo.require("dojo.data.ItemFileReadStore");
	jsonStore.fetch({query:"obj1",
		onComplete: function(item){
			var now = new Date().getTime();
			var result;
			for(var i=0;i<100000;i++){
			}
			console.log("Just Loop",new Date().getTime()-now, result);
			now = new Date().getTime();
			for(i=0;i<100000;i++){
				result = item.name;
			}
			console.log("Direct Access",new Date().getTime()-now, result);

			now = new Date().getTime();
			for(i=0;i<100000;i++){
				result = jsonStore.getValue(item,"name");
			}
			console.log("getValue",new Date().getTime()-now);

			var ifrs = new dojo.data.ItemFileReadStore({data:{ identifier:'id',items: [
				{ id:'1',name:'Fozzie Bear', wears:['hat', 'tie']},
				{ id:'2',name:'Miss Piggy', pets:'Foo-Foo'}
			]}});
			ifrs.fetchItemByIdentity({identity:'1',onItem:function(result){
				item = result;
			}});

			now = new Date().getTime();
			for(i=0;i<100000;i++){
				result = ifrs.getValue(item,"name");
			}
			console.log("ifrs.getValue",new Date().getTime()-now,result);

		}
	});

}

}


text:
'use strict';

module.exports = function(app) {
	var users = require('../../app/controllers/users.server.controller');
	var adverts = require('../../app/controllers/adverts.server.controller');

	// Adverts Routes
	app.route('/adverts')
		.get(adverts.list)
		.post(users.requiresLogin, adverts.create);

	app.route('/adverts/:advertId')
		.get(adverts.read)
		.put(users.requiresLogin, adverts.hasAuthorization, adverts.update)
		.delete(users.requiresLogin, adverts.hasAuthorization, adverts.delete);

	app.route('/adverts/pidroute/:advertPID')
		.get(adverts.read);

	app.route('/adverts/upload')
		.post(users.requiresLogin, adverts.fileUpload);

	// Finish by binding the Advert middleware
	app.param('advertId', adverts.advertByID);
	app.param('advertPID', adverts.advertByPID);
};


text:
package com.digiarea.closure.model.controller.dialogs;

import java.io.File;
import java.net.URL;
import java.util.ResourceBundle;

import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.control.ContentDisplay;
import javafx.scene.control.Label;
import javafx.scene.control.ListCell;
import javafx.scene.control.ListView;
import javafx.scene.paint.Color;
import javafx.stage.Stage;
import javafx.util.Callback;

import com.digiarea.closure.preferences.model.ClosureLibrary;
import com.digiarea.closure.preferences.model.bind.PreferencesSerializer;
import com.digiarea.closure.preferences.model.controller.PreferencesController;
import com.digiarea.closure.preferences.model.controller.PreferencesFactory;
import com.digiarea.closurefx.IConstants;
import com.digiarea.closurefx.build.validation.IStatus;
import com.digiarea.closurefx.build.validation.Status;

/**
 * FXML Controller class
 *
 * @author daginno
 */
public class SelectClosureDialogController implements Initializable {

	private Stage stage;

	@FXML
	private ListView<ClosureLibrary> controlLibraries;

	@FXML
	private Label controlMessage;

	private IStatus status = Status.CANCEL_STATUS;
	private ResourceBundle bundle;

	/**
	 * Initializes the controller class.
	 */
	@Override
	public void initialize(URL url, ResourceBundle rb) {
		bundle = rb;
		controlLibraries
				.setCellFactory(new Callback<ListView<ClosureLibrary>, ListCell<ClosureLibrary>>() {

					@Override
					public ListCell<ClosureLibrary> call(
							ListView<ClosureLibrary> list) {
						return new ClosureLibraryCell();
					}
				});
		loadClosureLibrarys();
	}

	private void loadClosureLibrarys() {
		PreferencesSerializer serializer = new PreferencesSerializer();
		controlLibraries.setItems(serializer.readLibraries()
				.librariesProperty());
	}

	@FXML
	private void handleClosureLibraryButtonAction(ActionEvent event) {
		PreferencesController controller = PreferencesFactory
				.getPreferenceDialog(bundle);
		controller.selectClosuresPage();
		loadClosureLibrarys();
	}

	@FXML
	private void handleOkButtonAction(ActionEvent event) {
		status = Status.OK_STATUS;
		stage.close();
	}

	@FXML
	private void handleCancelButtonAction(ActionEvent event) {
		status = Status.CANCEL_STATUS;
		stage.close();
	}

	public void setStage(Stage stage) {
		this.stage = stage;
	}

	public IStatus getStatus() {
		return status;
	}

	public ClosureLibrary getClosureLibrary() {
		return controlLibraries.getSelectionModel().getSelectedItem();
	}

	public class ClosureLibraryCell extends ListCell<ClosureLibrary> implements
			IConstants {

		public void updateItem(ClosureLibrary item, boolean empty) {
			super.updateItem(item, empty);
			if (empty) {
				setText(null);
			}
			if (item != null) {
				if (!new File(item.getPath()).exists()) {
					setPrefHeight(0);
					setPrefWidth(0);
					setVisible(false);
					setText(null);
					setGraphic(null);
				} else {
					setPrefHeight(getMinHeight());
					setPrefWidth(getMaxWidth());
					setVisible(true);
					setText(item.getName());
					Label label = new Label(item.getPath());
					label.setTextFill(Color.GRAY);
					setGraphic(label);
					setContentDisplay(ContentDisplay.RIGHT);
				}
			}
		}

	}

}


text:
package com.poiji.deserialize.model.byid;

import com.poiji.annotation.ExcelCellName;

/**
 * Created by hakan on 22/01/2017.
 */
public class Car extends Vehicle {

    @ExcelCellName("SEATS")
    private int nOfSeats;

    public int getnOfSeats() {
        return nOfSeats;
    }

    public void setnOfSeats(int nOfSeats) {
        this.nOfSeats = nOfSeats;
    }
}


text:
var test = require('test');

var extensionRe = /([^\/]+)\.extension$/;
var ExtensionLoader = function (config, load) {
    return function (id, module) {
        var match = extensionRe.exec(id);
        if (match) {
            module.redirect = id + "/" + match[1];
            return module;
        } else {
            return load(id, module);
        }
    };
};

var config = {};
config.makeLoader = function (config) {
    return ExtensionLoader(config, require.config.makeLoader(config));
};

return require.loadPackage(module.directory, config)
.then(function (packageRequire) {
    return packageRequire.async("a.extension");
})
.then(function (aExports) {
    test.assert(aExports === 10, 'require with extension loader');

    test.print('DONE', 'info');
});


text:
<?xml version="1.0" encoding="UTF-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
    <string name="app_label" msgid="8016145283189546017">"Indataenheter"</string>
    <string name="keyboard_layouts_label" msgid="6688773268302087545">"Androids tangentbord"</string>
    <string name="keyboard_layout_english_uk_label" msgid="6664258463319999632">"Engelskt (Storbritannien)"</string>
    <string name="keyboard_layout_english_us_label" msgid="8994890249649106291">"Engelskt (USA)"</string>
    <string name="keyboard_layout_english_us_intl" msgid="3705168594034233583">"Engelskt (USA), internationellt"</string>
    <string name="keyboard_layout_english_us_colemak_label" msgid="4194969610343455380">"Engelskt (USA), colemak"</string>
    <string name="keyboard_layout_english_us_dvorak_label" msgid="793528923171145202">"Engelskt (USA), dvorak"</string>
    <string name="keyboard_layout_german_label" msgid="8451565865467909999">"Tyskt"</string>
    <string name="keyboard_layout_french_label" msgid="813450119589383723">"Franskt"</string>
    <string name="keyboard_layout_french_ca_label" msgid="365352601060604832">"Franskt (Kanada)"</string>
    <string name="keyboard_layout_russian_label" msgid="8724879775815042968">"Ryskt"</string>
    <string name="keyboard_layout_russian_mac_label" msgid="3795866869038264796">"Ryskt, Mac"</string>
    <string name="keyboard_layout_spanish_label" msgid="7091555148131908240">"Spanskt"</string>
    <string name="keyboard_layout_swiss_french_label" msgid="4659191025396371684">"Franskt (Schweiz)"</string>
    <string name="keyboard_layout_swiss_german_label" msgid="2305520941993314258">"Tyskt (Schweiz)"</string>
    <string name="keyboard_layout_belgian" msgid="2011984572838651558">"Belgiskt"</string>
    <string name="keyboard_layout_bulgarian" msgid="8951224309972028398">"Bulgariskt"</string>
    <string name="keyboard_layout_italian" msgid="6497079660449781213">"Italienskt"</string>
    <string name="keyboard_layout_danish" msgid="8036432066627127851">"Danskt"</string>
    <string name="keyboard_layout_norwegian" msgid="9090097917011040937">"Norskt"</string>
    <string name="keyboard_layout_swedish" msgid="732959109088479351">"Svenskt"</string>
    <string name="keyboard_layout_finnish" msgid="5585659438924315466">"Finskt"</string>
    <string name="keyboard_layout_croatian" msgid="4172229471079281138">"Kroatiskt"</string>
    <string name="keyboard_layout_czech" msgid="1349256901452975343">"Tjeckiskt"</string>
    <string name="keyboard_layout_estonian" msgid="8775830985185665274">"Estniskt"</string>
    <string name="keyboard_layout_hungarian" msgid="4154963661406035109">"Ungerskt"</string>
    <string name="keyboard_layout_icelandic" msgid="5836645650912489642">"Isländskt"</string>
    <string name="keyboard_layout_brazilian" msgid="5117896443147781939">"Portugisiskt (Brasilien)"</string>
    <string name="keyboard_layout_portuguese" msgid="2888198587329660305">"Portugisiskt"</string>
    <string name="keyboard_layout_slovak" msgid="2469379934672837296">"Slovakiskt"</string>
    <string name="keyboard_layout_slovenian" msgid="1735933028924982368">"Slovenskt"</string>
    <string name="keyboard_layout_turkish" msgid="7736163250907964898">"Turkiskt"</string>
    <string name="keyboard_layout_ukrainian" msgid="8176637744389480417">"Ukrainskt"</string>
</resources>


text:
<?xml version="1.0" encoding="utf-8"?>
<full-backup-content>
    <!-- backup everything -->
</full-backup-content>


text:
// Contains utilities for launching compiled XLA kernels for a KernelContext.

#ifndef TENSORFLOW_COMPILER_JIT_XLA_LAUNCH_UTIL_H_
#define TENSORFLOW_COMPILER_JIT_XLA_LAUNCH_UTIL_H_

#include "tensorflow/compiler/jit/xla_compilation_cache.h"
#include "tensorflow/compiler/jit/xla_tensor.h"
#include "tensorflow/compiler/tf2xla/xla_compiler.h"
#include "tensorflow/compiler/xla/client/local_client.h"
#include "tensorflow/compiler/xla/service/shaped_buffer.h"
#include "tensorflow/core/framework/allocation_description.pb.h"
#include "tensorflow/core/framework/resource_var.h"
#include "tensorflow/core/framework/tensor.h"
#include "tensorflow/core/framework/types.h"
#include "tensorflow/core/lib/core/status.h"
#include "tensorflow/core/lib/gtl/array_slice.h"
#include "tensorflow/core/platform/thread_annotations.h"
#include "tensorflow/stream_executor/device_memory_allocator.h"

namespace tensorflow {

// Snapshot of resource variables for a TF kernel invocation, mapping from
// parameter number to values at execution time. If the resource variable is not
// initialized, the value will not be present.
using ResourceVarsSnapshot = absl::flat_hash_map<int, absl::optional<Tensor>>;

// Information about the state of a variable passed as input to the _XlaCompile
// and _XlaRun operators.  Unlocks the resource variable and decrements its
// refcount on destruction.
class VariableInfo {
 public:
  explicit VariableInfo(int index, absl::string_view name, Var* var,
                        const absl::optional<ManagedStackTrace>&
                            definition_stack_trace = absl::nullopt);
  VariableInfo(VariableInfo&& other);

  VariableInfo& operator=(VariableInfo&& other);

  VariableInfo(const VariableInfo&) = delete;
  VariableInfo& operator=(const VariableInfo&) = delete;

  // The index of the DT_RESOURCE input to the _XlaCompile/_XlaRun operator.
  // Note that the indices can be different between _XlaCompile and _XlaRun.
  int index() const { return index_; }

  // A pointer to the resource variable.  May be null if this VariableInfo is
  // "empty", i.e. it does not track a resource variable.
  Var* var() const { return var_; }

  // Returns the variable name.
  absl::string_view name() const { return name_; }

  // Returns true if the resource variable lock was successfully acquired by
  // this thread.
  bool lock_held() const { return lock_held_; }
  void set_lock_held() { lock_held_ = true; }

  const absl::optional<ManagedStackTrace>& definition_stack_trace() const {
    return definition_stack_trace_;
  }

  ~VariableInfo();

 private:
  int index_;
  std::string name_;
  Var* var_;
  absl::optional<ManagedStackTrace> definition_stack_trace_;

  // We can't use a optional<mutex_lock> here because it confuses the compiler's
  // thread safety analysis. Instead we use a boolean flag and release the lock
  // in the VariableInfo destructor.
  bool lock_held_ = false;
};

// Creates a list of updated resource variables.
StatusOr<std::vector<VariableInfo>> GatherVariableInfo(
    OpKernelContext* ctx,
    const XlaCompiler::CompilationResult& compilation_result,
    int missing_ctx_input_prefix);

// Takes a snapshot of the values of resource variable arguments, whose indices
// are specified in `variable_indices` argument. We snapshot tensors that back
// resource variables since concurrent updates may modify the shape, and it is
// important that the shapes used for compilation match the true shapes of the
// buffers.
//
// We snapshot the entire set of resource variables as one atomic operation.
// This models Read->* dependencies between resource variable operations.  See
// jit/resource_operation_safety_analysis for details.
Status SnapshotResourceVariables(OpKernelContext* ctx,
                                 absl::Span<const int> variable_indices,
                                 absl::Span<VariableInfo const> variable_infos,
                                 ResourceVarsSnapshot* result);

// Acquires the mutexes for all the variables in `variables` using a
// deadlock-safe protocol (acquire the mutexes in increasing-address order).
//
// `variables` is allowed to contain instances that don't track a resource
// variable (i.e. variables[i].var() can be null for some i).
Status LockVariables(absl::Span<VariableInfo> variables)
    TF_EXCLUSIVE_LOCK_FUNCTION();

// Returns a vector of VariableInfo instances for the resource variable inputs,
// given that *all* inputs are in `inputs`. The input indices for the resource
// variable inputs are in `variable_indices`.
Status GetVariableInfosFromInputs(ResourceMgr* rm, DeviceBase* dev,
                                  absl::Span<const Tensor* const> inputs,
                                  absl::Span<const int> variable_indices,
                                  std::vector<VariableInfo>* result);

// Returns pointers to inputs stored in `ctx`.
std::vector<const Tensor*> InputsFromContext(OpKernelContext* ctx);

// Helper class to perform the marshalling of TensorFlow inputs and outputs to
// ShapedBuffers suitable for passing to an XLA computation.
class XlaComputationLaunchContext {
 public:
  // Create a new launch context. 'allocate_xla_tensors' is true if allocated
  // output tensors and variables are always XlaTensors. If false they are
  // assumed to be "normal" device pointers.
  // If 'use_multiple_streams' is true, tensors may be defined and used on
  // multiple streams and so se::Events must be defined and waited for. If
  // 'use_multiple_streams' is true, 'allocate_xla_tensors' must also be true
  // because we track inter-stream dependencies through events inside XlaTensor
  // objects.
  XlaComputationLaunchContext(xla::LocalClient* client,
                              se::DeviceMemoryAllocator* xla_allocator,
                              int device_ordinal, bool allocate_xla_tensors,
                              bool use_multiple_streams);

  // Builds a XlaCompiler::Argument vector from the arguments to an XlaLaunch
  // op.
  // Precondition: variables in `variable_args` are locked.
  static StatusOr<std::vector<XlaCompiler::Argument>> BuildXlaCompilerArguments(
      absl::Span<int const> must_be_constant_idxs,
      absl::Span<const Tensor* const> inputs,
      absl::Span<VariableInfo const> variable_args, Device* device);

  // Add all inputs within `ctx` as XLA arguments (returned by arguments()).
  // `variables` is a map from TensorFlow argument number to resource variable.
  //
  // Assumes that the first `missing_ctx_input_prefix` inputs to the kernel are
  // missing and adjusts input indices accordingly.  All elements in kernel's
  // input_mapping must be greater than or equal to `missing_ctx_input_prefix`
  // (in other words, no inputs actually required by the kernel can be missing).
  StatusOr<std::vector<xla::ExecutionInput>> PopulateInputs(
      OpKernelContext* ctx,
      const XlaCompiler::CompilationResult* compilation_result,
      const std::map<int, const Tensor*>& resource_vars,
      int missing_ctx_input_prefix,
      const xla::HloInputOutputAliasConfig& input_output_alias);

  // Given the XLA output in `output`, populate all outputs of `ctx`.  Also
  // writes out the resource variable updates.
  //
  // Updates to all resource variables are written in a single atomic operation.
  // This models *->Write dependencies between resource variable operations.
  // See jit/resource_operation_safety_analysis for details.
  //
  //
  // Assumes that the first `missing_ctx_input_prefix` inputs to the
  // compilation_result are missing and adjusts input indices accordingly.
  Status PopulateOutputs(
      OpKernelContext* ctx,
      const XlaCompiler::CompilationResult* compilation_result,
      xla::ScopedShapedBuffer output, int missing_ctx_input_prefix,
      absl::Span<VariableInfo> variable_infos,
      const xla::HloInputOutputAliasConfig& input_output_alias,
      const std::map<int, const Tensor*>& resource_vars);

 private:
  xla::LocalClient* client_;
  se::DeviceMemoryAllocator* xla_allocator_;
  bool allocate_xla_tensors_;
  bool use_multiple_streams_;
  int device_ordinal_;
};

// A simple TensorBuffer implementation that allows us to create Tensors that
// take ownership of pre-allocated memory.
class XlaTensorBuffer : public TensorBuffer {
 public:
  XlaTensorBuffer(const void* ptr, size_t expected_size, size_t actual_size,
                  Allocator* allocator)
      : TensorBuffer(const_cast<void*>(ptr)),
        expected_size_(expected_size),
        actual_size_(actual_size),
        allocator_(allocator) {}

  ~XlaTensorBuffer() override {
    if (data()) {
      allocator_->DeallocateRaw(data());
    }
  }

  size_t size() const override { return expected_size_; }

  TensorBuffer* root_buffer() override { return this; }

  void FillAllocationDescription(AllocationDescription* proto) const override {
    proto->set_requested_bytes(static_cast<int64>(expected_size_));
    proto->set_allocator_name(allocator_->Name());
    proto->set_ptr(reinterpret_cast<uintptr_t>(data()));
    if (allocator_->TracksAllocationSizes()) {
      auto ab = static_cast<int64>(allocator_->AllocatedSize(data()));
      proto->set_allocated_bytes(ab);
      int64 id = allocator_->AllocationId(data());
      if (id > 0) {
        proto->set_allocation_id(id);
      }
      if (RefCountIsOne()) {
        proto->set_has_single_reference(true);
      }
    }
  }

 private:
  size_t expected_size_;
  size_t actual_size_;
  Allocator* allocator_;
};

}  // namespace tensorflow

#endif  // TENSORFLOW_COMPILER_JIT_XLA_LAUNCH_UTIL_H_


text:
using System;
using System.Collections.Generic;
using System.Text;
using GroupDocs.Annotation.Models.AnnotationModels;

namespace GroupDocs.Annotation.Examples.CSharp.AdvancedUsage
{
    /// <summary>
    /// This example demonstrates getting list of annotations from document using version key
    /// </summary>
    class GetListOfAnnotationsUsingVersionKey
    {
        public static void Run()
        {
            using (Annotator annotator = new Annotator(Constants.ANNOTATED_WITH_VERSIONS))
            {
                List<AnnotationBase> annotations = annotator.GetVersion("CUSTOM_VERSION");
            }
        }
    }
}


text:
/*global define */
/*
 | Copyright 2014 Esri
 |
 | 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.
 */
define(
     ({
        map: {
            error: "Impossible de créer la carte",
            zoomInTooltip: "Zoom avant",  // Command button to zoom in to the map
            zoomOutTooltip: "Zoom arrière",  // Command button to zoom out of the map
            geolocationTooltip: "Position actuelle"  // Command button to navigate to the current geographical position
        },
        main: {
            noGroup: "Aucun groupe configuré", // Shown when no group is configured in the configuration file
            submitReportButtonText: "Envoyer un rapport", //Submit report  text for buttons on map and list
            gotoListViewTooltip: "Vue Liste", // Go to List view tooltip text
            noFeatureGeomtery: "Impossible d\'afficher l\'entité" // Error message when geomtery is not available
        },
        signin: {
            guestSigninText: "Continuer comme invité", // Shown in the 'Sign in' page below the icon for accessing application as an anonymous user
            signInOrText: "Ou", // Or text on sign in screen
            signinOptionsText: "Se connecter avec :", // Shown in the 'Sign in' page above the icons for social media sign in
            noGroupNameText: "Connectez-vous", // Shown when the group title is not available or the group is private
            guestLoginTooltip: "Se connecter comme invité", // Command button to access the application as an anonymous user
            facebookLoginTooltip: "Se connecter avec Facebook", // Command button to access the application via Facebook login
            twitterLoginTooltip: "Se connecter avec Twitter", // Command button to access the application via Twitter login
            googlePlusLoginTooltip: "Se connecter avec Google+", // Command button to access the application via Google+ login
            agolLoginTooltip: "Se connecter avec ArcGIS" // Command button to access the application via AGOL login
        },
        webMapList: {
            owner: "Propriétaire", // Shown in the 'Map information' section indicating the owner of the webmap
            created: "Date de création", // Shown in the 'Map information' section indicating the date when the webmap was created
            modified: "Date de modification", // Shown in the 'Map information' section indicating the date when the webmap was modified
            description: "Description", // Shown in the 'Map information' section describing the webmap
            snippet: "Résumé", // Shown in the 'Map information' section providing the summary of the webmap
            licenseInfo: "Restrictions d\'accès et d\'utilisation", // Shown in the map information section indicating the webmap license information
            accessInformation: "Crédits", // Shown in the 'Map information' section indicating account credits
            tags: "Balises", // Shown in the 'Map information' section indicating tags of the webmap
            numViews: "Nombre de vues", // Shown in the 'Map information' section indicating number of times the webmap has been viewed
            avgRating: "Evaluation", // Shown in the 'Map information' section indicating webmap rating
            noWebMapInGroup: "Le groupe configuré n\'est pas valide ou aucun élément n\'a encore été partagé avec ce groupe.", // Shown when the configured group is invalid/private or no items have been shared with the group
            infoBtnToolTip: "Informations sur la carte" // Command button to view the 'Map information'
        },
        issueWall: {
            noResultsFound: "Aucun rapport n\'est disponible dans la zone actuelle", // Shown in the issue wall when no issues are present in the current map extent
            gotoWebmapListTooltip: "Accéder à la liste principale", // Tooltip for back icon in list header
            gotoMapViewTooltip: "Vue cartographique" // Tooltip for map-it icon in list header
        },
        appHeader: {
            myReport: "Mes rapports", // Command button shown in mobile menu list
            signIn: "Connexion", // Command button shown in mobile menu list and in appheader
            signOut: "Déconnexion", // Command button shown in mobile menu list
            help: "Aide", // Command button shown in mobile menu list
            signInTooltip: "Connexion", // Tooltip to 'Sign in' option
            signOutTooltip: "Déconnexion", // Tooltip  to 'Sign out' option
            myReportTooltip: "Afficher les rapports que j\'ai envoyés", // Tooltip  to 'My Reports' option
            helpTooltip: "Aide" // Tooltip  to 'Help' option
        },
        geoform: {
            enterInformation: "Détails", // Shown as the first section of the geoform, where the user can enter details of the issue
            selectAttachments: "Pièces jointes", // Appears above 'Select file' button indicating option to attach files
            selectFileText: "Parcourir", // Command button to open a dialog box to select file(s) to be attached
            enterLocation: "Emplacement", // Shown as the second section of the geoform, where the user can select a location on the map
            reportItButton: "Signaler", // Command button to submit the geoform to report an issue
            cancelButton: "Annuler", //Command button to close the geoform
            requiredField: "(requis)", // Shown next to the field in which the data is mandatory
            selectDefaultText: "Sélectionner…", // Shown in the dropdown field indicating to select an option
            invalidInputValue: "Entrez une valeur valide.", // Shown when user clicks/taps the required field but does not enter the data and comes out of the required field
            noFieldsConfiguredMessage: "Les champs de couche ne sont pas configurés pour capturer les données", // Shown when all the fields of the selected layer are disabled
            invalidSmallNumber: "Entrez un entier", // Shown when the entered value is beyond the specified range (valid ${openStrong}integer${closeStrong} value between -32768 and 32767.)
            invalidNumber: "Entrez un entier", // Shown when the entered value is beyond the specified range (valid ${openStrong}integer${closeStrong} value between -2147483648 and 2147483647.)
            invalidFloat: "Please enter a number", // Shown when the entered value is beyond the specified range (valid ${openStrong}floating point${closeStrong} value between -3.4E38 and 1.2E38 )
            invalidDouble: "Please enter a number", // Shown when the entered value is beyond the specified range (valid ${openStrong}double${closeStrong} value between -2.2E308 and 1.8E308)
            requiredFields: "Indiquez des valeurs pour tous les champs requis", // Shown when user submits the geoform without entering data in the mandatory field(s)
            selectLocation: "Sélectionnez l\'emplacement de votre rapport", // Shown when user submits the geoform without selecting location on the map
            numericRangeHintMessage: "${openStrong}Astuce :${closeStrong} valeur minimale ${minValue} et valeur maximale ${maxValue}", // Shown as a pop over above the fields with numeric values, indicating the minimum and maximum range
            dateRangeHintMessage: "${openStrong}Astuce :${closeStrong} date minimum ${minValue} et date maximum ${maxValue}", // Shown as a pop over above the fields with date values, indicating the minimum and maximum date range
            errorsInApplyEdits: "Impossible de signaler le problème", // Shown when there is an error in any of the services while submitting the geoform
            attachmentSelectedMsg: "pièce(s) jointe(s) sélectionnée(s)", // Shown besides the select file button indicating the number of files attached
            attachmentUploadStatus: "Echec du chargement de ${failed} sur ${total} pièce(s) jointe(s)", // Shown when there is error while uploading the attachment, while submitting the geoform
            geoLocationError: "Localisant actuel non disponible",  // Shown when the browser returns an error instead of the current geographical position
            geoLocationOutOfExtent: "L\'étendue courante est en dehors de l\'étendue du fond de carte",  // Shown when the current geographical position is out of the basemap extent
            submitButtonTooltip: "Signaler", // Command button to open the geoform
            cancelButtonTooltip: "Annuler", //tooltip for cancel button
            geoformBackButtonTooltip: "Accéder à la liste des rapports" //tooltip for Geoform back button

        },
        locator: {
            addressText: "Adresse :", // Shown as a title for a group of addresses returned on performing unified search
            usngText: "USNG", // Shown as a title for a group of USNG values returned on performing unified search
            mgrsText: "MGRS", // Shown as a title for a group of MGRS values returned on performing unified search
            latLongText: "Latitude/Longitude", // Shown as a title for a group of latitude longitude values returned on performing unified search
            invalidSearch: "Aucun résultat trouvé", // Shown in the address container when no results are returned on performing unified search
            locatorPlaceholder: "Entrer une adresse à rechercher", // Shown in the address container textbox as a placeholder
            locationOutOfExtent: "L\'adresse localisée est en dehors de l\'étendue du fond de carte", // Shown as an alert when the selected address in the search result is out of basemap extent
            searchButtonTooltip: "Rechercher", // Tooltip for search button
            clearButtonTooltip: "Effacer la valeur de recherche" // Tooltip for Geocoder clear button
        },
        myIssues: {
            title: "Mes rapports", // Shown as a title in 'My issues' panel
            myIssuesTooltip: "Mes rapports", // Command button to access issues reported by the logged in user
            noResultsFound: "Aucun rapport trouvé" // Shown when no issues are reported by the logged in user
        },
        itemDetails: {  // Detailed information about an item and a list of its comments
            likeButtonLabel: "Comme", // Command button shown in details panel
            likeButtonTooltip: "Voter pour ce rapport",  // Tooltip for command button shown in details panel
            commentButtonLabel: "Commentaire", // Command button shown in details panel
            commentButtonTooltip: "Commenter ce rapport", // Tooltip for command button shown in details panel
            galleryButtonLabel: "Bibliothèque", // Command button shown in details panel
            galleryButtonTooltip: "Voir les documents joints", // Tooltip for command button shown in details panel
            mapButtonLabel: "Afficher sur la carte", // Command button shown in details panel
            mapButtonTooltip: "Afficher l\'emplacement de ce rapport", // Tooltip for command button shown in details panel
            commentsListHeading: "Commentaires", // List heading for Comments section in details panel
            unableToUpdateVoteField: "Il est actuellement impossible d\'ajouter votre vote.", // Error message for feature unable to update
            gotoIssueListTooltip: "Accéder à la liste des rapports" // Tooltip for back icon in Issue list header
        },
        itemList: {  // List of feature layer items shown in my-issues and issue-wall
            likesForThisItemTooltip: "Votes pour ce rapport" //Shown on hovering of the like icon in my-issues and issue-wall
        },
        comment: {
            commentsFormText: "Commentaire",
            commentsFormSubmitButton: "Envoyer un commentaire",
            commentsFormCancelButton: "Annuler",
            errorInSubmittingComment: "Impossible d\'envoyer le commentaire.", // Shown when user is unable to add comments
            emptyCommentMessage: "Saisissez un commentaire.", // Shown when user submits a comment without any text/character
            placeHolderText: "Saisir un commentaire", // Shown as a placeholder in comments textbox
            noCommentsAvailableText: "Aucun commentaire disponible", // Shown when no comments are available for the selected issue
            remainingTextCount: "${0} caractère(s) restant(s)", // Shown below the comments textbox indicating the number of characters that can be added
            showNoText: "Non" // Shown when comments character limit is exceeded
        },
        gallery: {
            galleryHeaderText: "Bibliothèque",
            noAttachmentsAvailableText: "Aucune pièce jointe trouvée" // Shown when no comments are available for the selected issue
        }
    })
);


text:
static NSString *const kFileExtensionGif = @"gif";

@implementation ShotModel

//TODO:key mapper

//+ (JSONKeyMapper *)keyMapper {
//    return [];
//}

- (NSString<Ignore> *)defaultUrl {
    return self.imageModel.hidpi ? self.imageModel.hidpi : self.imageModel.normal;
}

- (NSString<Ignore> *)fileType {
    return [[self.defaultUrl pathExtension] lowercaseString];
}

- (NSNumber<Ignore> *)authorityId {
    return self.userModel ? self.userModel.userId : self.teamModel.teamId;
}

- (BOOL)isAnimation {
    return [self.fileType isEqualToString:kFileExtensionGif];
}

- (BOOL)isEqual:(id)object {
    ShotModel *shot = (ShotModel *)object;
    return [shot.shotId isEqualToNumber:self.shotId];
}

- (NSUInteger)hash {
    return [[self.shotId stringValue] hash];
}

@end


text:
(function() {
    var params = ParameterParser.parse();
    var roomName = params.room;

    function runAtMidnight(func) {
        var oneDay = 1000 * 60 * 60 * 24;

        var midnight = new Date(new Date().getTime() + oneDay);
        midnight.setSeconds(0); midnight.setMinutes(0);midnight.setHours(0);

        // paranoia
        while (midnight < new Date()) {
            midnight = new Date(midnight.getTime() + oneDay);
        }

        setTimeout(func, midnight - new Date());
    }
    function runEveryNMinutesOnTheMthSecond(n, m, func) {
        var firstDelaySec = m - (DebugSettings.now() || new Date()).getSeconds();
        if (firstDelaySec <= 0) {
            firstDelaySec +=  10;
        }

        setTimeout(function() {
            try {
                func();
                setInterval(function() {
                    func();
                }, 1000 * 10 * n);
            } catch (err) {
                Logger.log("Error in repeated function.", err);
            }
        }, firstDelaySec * 1000);
    }

    function getRootUrl() {
        var qsStart = window.location.href.indexOf('?');
        var hashStart = window.location.href.indexOf('#');
        var url = window.location.href.substring(0,
            Math.min(~qsStart ? qsStart : Infinity, ~hashStart ? hashStart : Infinity));

        if (url.lastIndexOf('/') !== url.length - 1) {
            url += '/';
        }
        return url;
    }

    function updateRooms() {
        EventManager.update(function success(newRooms) {
            _.each(newRooms, function(room) {
                GlobalEvents.trigger('roomLoaded', room);
            });
            _.each(EventManager.rooms, function(room) {
                GlobalEvents.trigger('roomUpdatedByServer', room);
            });
        }, function error() {
            console.log('Error while updating rooms.');
        });
    }

    DebugSettings.init(getRootUrl());
    EventManager.init(getRootUrl(), params.secret, function(newRooms) {
        var thisRoom = roomName ? EventManager.getRoom(roomName) : undefined;

        if (roomName && !thisRoom) {
            $('#errormsg')
                .css('font-size','18px')
                .text('You entered an invalid room name.  The room could not be found.')
                .removeClass('hidden');
            $('#container').addClass('hidden');
            return;
        }

        UI.init(thisRoom);

        _.each(newRooms, function(room) {
            GlobalEvents.trigger('roomLoaded', room);
        });

        runEveryNMinutesOnTheMthSecond(1, 31, updateRooms);

        //update UI when the minute ticks over.
        runEveryNMinutesOnTheMthSecond(1, 1, function() { GlobalEvents.trigger('minuteChanged'); });
    });

    GlobalEvents.bind('bookingAddedByUser', function(event, booking) {
        EventManager.bookRoom(booking.room, booking.time, booking.duration,
            function success() {
                updateRooms();
            },
            function failure() {
                GlobalEvents.trigger('bookingFailure', booking);
            }
        );
    });

    // update MEET from server everyday at midnight.
    runAtMidnight(function() { window.location.reload(); });
})();


text:
import os
import sys
import time
import json

from common.basedir import BASEDIR
from common.params import Params
from selfdrive.controls.lib.alertmanager import set_offroad_alert

if __name__ == "__main__":
  params = Params()

  with open(os.path.join(BASEDIR, "selfdrive/controls/lib/alerts_offroad.json")) as f:
    offroad_alerts = json.load(f)

  t = 10 if len(sys.argv) < 2 else int(sys.argv[1])
  while True:
    print("setting alert update")
    params.put_bool("UpdateAvailable", True)
    r = open(os.path.join(BASEDIR, "RELEASES.md")).read()
    r = r[:r.find('\n\n')]  # Slice latest release notes
    params.put("UpdaterNewReleaseNotes", r + "\n")

    time.sleep(t)
    params.put_bool("UpdateAvailable", False)

    # cycle through normal alerts
    for a in offroad_alerts:
      print("setting alert:", a)
      set_offroad_alert(a, True)
      time.sleep(t)
      set_offroad_alert(a, False)

    print("no alert")
    time.sleep(t)