text:
#define DT_DRV_COMPAT nxp_pca95xx

/**
 * @file Driver for PCA95XX and PCAL95XX I2C-based GPIO driver.
 */

#include <errno.h>

#include <zephyr/kernel.h>
#include <zephyr/device.h>
#include <zephyr/init.h>
#include <zephyr/sys/byteorder.h>
#include <zephyr/sys/util.h>
#include <zephyr/drivers/gpio.h>
#include <zephyr/drivers/i2c.h>

#include <zephyr/drivers/gpio/gpio_utils.h>

#define LOG_LEVEL CONFIG_GPIO_LOG_LEVEL
#include <zephyr/logging/log.h>
LOG_MODULE_REGISTER(gpio_pca95xx);

/* Register definitions */
#define REG_INPUT_PORT0			0x00
#define REG_INPUT_PORT1			0x01
#define REG_OUTPUT_PORT0		0x02
#define REG_OUTPUT_PORT1		0x03
#define REG_POL_INV_PORT0		0x04
#define REG_POL_INV_PORT1		0x05
#define REG_CONF_PORT0			0x06
#define REG_CONG_PORT1			0x07
#define REG_OUT_DRV_STRENGTH_PORT0_L	0x40
#define REG_OUT_DRV_STRENGTH_PORT0_H	0x41
#define REG_OUT_DRV_STRENGTH_PORT1_L	0x42
#define REG_OUT_DRV_STRENGTH_PORT1_H	0x43
#define REG_INPUT_LATCH_PORT0		0x44
#define REG_INPUT_LATCH_PORT1		0x45
#define REG_PUD_EN_PORT0		0x46
#define REG_PUD_EN_PORT1		0x47
#define REG_PUD_SEL_PORT0		0x48
#define REG_PUD_SEL_PORT1		0x49
#define REG_INT_MASK_PORT0		0x4A
#define REG_INT_MASK_PORT1		0x4B
#define REG_INT_STATUS_PORT0		0x4C
#define REG_INT_STATUS_PORT1		0x4D
#define REG_OUTPUT_PORT_CONF		0x4F

/* Driver flags */
#define PCA_HAS_PUD			BIT(0)
#define PCA_HAS_INTERRUPT		BIT(1)
#define PCA_HAS_INTERRUPT_MASK_REG	BIT(2)

/** Configuration data */
struct gpio_pca95xx_config {
	/* gpio_driver_config needs to be first */
	struct gpio_driver_config common;
	struct i2c_dt_spec bus;
	uint8_t capabilities;
#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
	struct gpio_dt_spec int_gpio;
#endif
};

/** Runtime driver data */
struct gpio_pca95xx_drv_data {
	/* gpio_driver_data needs to be first */
	struct gpio_driver_data common;

	struct {
		uint16_t input;
		uint16_t output;
		uint16_t dir;
		uint16_t pud_en;
		uint16_t pud_sel;
		uint16_t int_mask;
	} reg_cache;

	struct k_sem lock;

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
	/* Self-reference to the driver instance */
	const struct device *instance;

	/* port ISR callback routine address */
	sys_slist_t callbacks;

	/* interrupt triggering pin masks */
	struct {
		uint16_t edge_rising;
		uint16_t edge_falling;
		uint16_t level_high;
		uint16_t level_low;
	} interrupts;

	struct gpio_callback gpio_callback;

	struct k_work interrupt_worker;

	bool interrupt_active;
#endif
};

/**
 * @brief Read both port 0 and port 1 registers of certain register function.
 *
 * Given the register in reg, read the pair of port 0 and port 1.
 *
 * @param dev Device struct of the PCA95XX.
 * @param reg Register to read (the PORT0 of the pair of registers).
 * @param cache Pointer to the cache to be updated after successful read.
 * @param buf Buffer to read data into.
 *
 * @return 0 if successful, failed otherwise.
 */
static int read_port_regs(const struct device *dev, uint8_t reg,
			  uint16_t *cache, uint16_t *buf)
{
	const struct gpio_pca95xx_config * const config = dev->config;
	uint16_t port_data, value;
	int ret;

	ret = i2c_burst_read_dt(&config->bus, reg, (uint8_t *)&port_data,
				sizeof(port_data));
	if (ret != 0) {
		LOG_ERR("PCA95XX[0x%X]: error reading register 0x%X (%d)",
			config->bus.addr, reg, ret);
		return ret;
	}

	value = sys_le16_to_cpu(port_data);
	*cache = value;
	*buf = value;

	LOG_DBG("PCA95XX[0x%X]: Read: REG[0x%X] = 0x%X, REG[0x%X] = 0x%X",
		config->bus.addr, reg, (*buf & 0xFF), (reg + 1), (*buf >> 8));

	return 0;
}

/**
 * @brief Write both port 0 and port 1 registers of certain register function.
 *
 * Given the register in reg, write the pair of port 0 and port 1.
 *
 * @param dev Device struct of the PCA95XX.
 * @param reg Register to write into (the PORT0 of the pair of registers).
 * @param cache Pointer to the cache to be updated after successful write.
 * @param value New value to set.
 *
 * @return 0 if successful, failed otherwise.
 */
static int write_port_regs(const struct device *dev, uint8_t reg,
			   uint16_t *cache, uint16_t value)
{
	const struct gpio_pca95xx_config * const config = dev->config;
	uint8_t buf[3];
	int ret;

	LOG_DBG("PCA95XX[0x%X]: Write: REG[0x%X] = 0x%X, REG[0x%X] = "
		"0x%X", config->bus.addr, reg, (value & 0xFF),
		(reg + 1), (value >> 8));

	buf[0] = reg;
	sys_put_le16(value, &buf[1]);

	ret = i2c_write_dt(&config->bus, buf, sizeof(buf));
	if (ret == 0) {
		*cache = value;
	} else {
		LOG_ERR("PCA95XX[0x%X]: error writing to register 0x%X "
			"(%d)", config->bus.addr, reg, ret);
	}

	return ret;
}

static inline int update_input_regs(const struct device *dev, uint16_t *buf)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return read_port_regs(dev, REG_INPUT_PORT0,
			      &drv_data->reg_cache.input, buf);
}

static inline int update_output_regs(const struct device *dev, uint16_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return write_port_regs(dev, REG_OUTPUT_PORT0,
			       &drv_data->reg_cache.output, value);
}

static inline int update_direction_regs(const struct device *dev,
					uint16_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return write_port_regs(dev, REG_CONF_PORT0,
			       &drv_data->reg_cache.dir, value);
}

static inline int update_pul_sel_regs(const struct device *dev,
				      uint16_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return write_port_regs(dev, REG_PUD_SEL_PORT0,
			       &drv_data->reg_cache.pud_sel, value);
}

static inline int update_pul_en_regs(const struct device *dev, uint16_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return write_port_regs(dev, REG_PUD_EN_PORT0,
			       &drv_data->reg_cache.pud_en, value);
}

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
static inline int update_int_mask_regs(const struct device *dev, uint16_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	return write_port_regs(dev, REG_INT_MASK_PORT0,
			       &drv_data->reg_cache.int_mask, value);
}
#endif /* CONFIG_GPIO_PCA95XX_INTERRUPT */

/**
 * @brief Setup the pin direction (input or output)
 *
 * @param dev Device struct of the PCA95XX
 * @param pin The pin number
 * @param flags Flags of pin or port
 *
 * @return 0 if successful, failed otherwise
 */
static int setup_pin_dir(const struct device *dev, uint32_t pin, int flags)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t reg_dir = drv_data->reg_cache.dir;
	uint16_t reg_out = drv_data->reg_cache.output;
	int ret;

	/* For each pin, 0 == output, 1 == input */
	if ((flags & GPIO_OUTPUT) != 0U) {
		if ((flags & GPIO_OUTPUT_INIT_HIGH) != 0U) {
			reg_out |= BIT(pin);
		} else if ((flags & GPIO_OUTPUT_INIT_LOW) != 0U) {
			reg_out &= ~BIT(pin);
		}
		ret = update_output_regs(dev, reg_out);
		if (ret != 0) {
			return ret;
		}
		reg_dir &= ~BIT(pin);
	} else {
		reg_dir |= BIT(pin);
	}

	ret = update_direction_regs(dev, reg_dir);

	return ret;
}

/**
 * @brief Setup the pin pull up/pull down status
 *
 * @param dev Device struct of the PCA95XX
 * @param pin The pin number
 * @param flags Flags of pin or port
 *
 * @return 0 if successful, failed otherwise
 */
static int setup_pin_pullupdown(const struct device *dev, uint32_t pin,
				int flags)
{
	const struct gpio_pca95xx_config * const config = dev->config;
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t reg_pud;
	int ret;

	if ((config->capabilities & PCA_HAS_PUD) == 0) {
		/* Chip does not support pull up/pull down */
		if ((flags & (GPIO_PULL_UP | GPIO_PULL_DOWN)) != 0U) {
			return -ENOTSUP;
		}

		/* If both GPIO_PULL_UP and GPIO_PULL_DOWN are not set,
		 * we should disable them in hardware. But need to skip
		 * if the chip does not support pull up/pull down.
		 */
		return 0;
	}

	/* If disabling pull up/down, there is no need to set the selection
	 * register. Just go straight to disabling.
	 */
	if ((flags & (GPIO_PULL_UP | GPIO_PULL_DOWN)) != 0U) {
		/* Setup pin pull up or pull down */
		reg_pud = drv_data->reg_cache.pud_sel;

		/* pull down == 0, pull up == 1 */
		WRITE_BIT(reg_pud, pin, (flags & GPIO_PULL_UP) != 0U);

		ret = update_pul_sel_regs(dev, reg_pud);
		if (ret) {
			return ret;
		}
	}

	/* enable/disable pull up/down */
	reg_pud = drv_data->reg_cache.pud_en;

	WRITE_BIT(reg_pud, pin,
		  (flags & (GPIO_PULL_UP | GPIO_PULL_DOWN)) != 0U);

	ret = update_pul_en_regs(dev, reg_pud);

	return ret;
}

/**
 * @brief Configure pin or port
 *
 * @param dev Device struct of the PCA95XX
 * @param pin The pin number
 * @param flags Flags of pin or port
 *
 * @return 0 if successful, failed otherwise
 */
static int gpio_pca95xx_config(const struct device *dev,
			       gpio_pin_t pin, gpio_flags_t flags)
{
	int ret;
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

#if (CONFIG_GPIO_LOG_LEVEL >= LOG_LEVEL_DEBUG)
	const struct gpio_pca95xx_config * const config = dev->config;
#endif

	/* Does not support disconnected pin */
	if ((flags & (GPIO_INPUT | GPIO_OUTPUT)) == GPIO_DISCONNECTED) {
		return -ENOTSUP;
	}

	/* Open-drain support is per port, not per pin.
	 * So can't really support the API as-is.
	 */
	if ((flags & GPIO_SINGLE_ENDED) != 0U) {
		return -ENOTSUP;
	}

	/* Can't do I2C bus operations from an ISR */
	if (k_is_in_isr()) {
		return -EWOULDBLOCK;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	ret = setup_pin_dir(dev, pin, flags);
	if (ret) {
		LOG_ERR("PCA95XX[0x%X]: error setting pin direction (%d)",
			config->bus.addr, ret);
		goto done;
	}

	ret = setup_pin_pullupdown(dev, pin, flags);
	if (ret) {
		LOG_ERR("PCA95XX[0x%X]: error setting pin pull up/down "
			"(%d)", config->bus.addr, ret);
		goto done;
	}

done:
	k_sem_give(&drv_data->lock);
	return ret;
}

static int gpio_pca95xx_port_get_raw(const struct device *dev,
				     uint32_t *value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t buf;
	int ret;

	/* Can't do I2C bus operations from an ISR */
	if (k_is_in_isr()) {
		return -EWOULDBLOCK;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	ret = update_input_regs(dev, &buf);
	if (ret != 0) {
		goto done;
	}

	*value = buf;

done:
	k_sem_give(&drv_data->lock);
	return ret;
}

static int gpio_pca95xx_port_set_masked_raw(const struct device *dev,
					      uint32_t mask, uint32_t value)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t reg_out;
	int ret;

	/* Can't do I2C bus operations from an ISR */
	if (k_is_in_isr()) {
		return -EWOULDBLOCK;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	reg_out = drv_data->reg_cache.output;
	reg_out = (reg_out & ~mask) | (mask & value);

	ret = update_output_regs(dev, reg_out);

	k_sem_give(&drv_data->lock);

	return ret;
}

static int gpio_pca95xx_port_set_bits_raw(const struct device *dev,
					  uint32_t mask)
{
	return gpio_pca95xx_port_set_masked_raw(dev, mask, mask);
}

static int gpio_pca95xx_port_clear_bits_raw(const struct device *dev,
					    uint32_t mask)
{
	return gpio_pca95xx_port_set_masked_raw(dev, mask, 0);
}

static int gpio_pca95xx_port_toggle_bits(const struct device *dev,
					 uint32_t mask)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t reg_out;
	int ret;

	/* Can't do I2C bus operations from an ISR */
	if (k_is_in_isr()) {
		return -EWOULDBLOCK;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	reg_out = drv_data->reg_cache.output;
	reg_out ^= mask;

	ret = update_output_regs(dev, reg_out);

	k_sem_give(&drv_data->lock);

	return ret;
}

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
static void gpio_pca95xx_interrupt_worker(struct k_work *work)
{
	struct gpio_pca95xx_drv_data * const drv_data = CONTAINER_OF(
		work, struct gpio_pca95xx_drv_data, interrupt_worker);
	uint16_t input_new, input_cache, changed_pins, trig_edge;
	uint16_t trig_level = 0;
	uint32_t triggered_int = 0;
	int ret;

	k_sem_take(&drv_data->lock, K_FOREVER);

	input_cache = drv_data->reg_cache.input;

	ret = update_input_regs(drv_data->instance, &input_new);
	if (ret == 0) {
		/* Note: PCA Interrupt status is cleared by reading inputs */

		changed_pins = (input_cache ^ input_new);

		trig_edge = (changed_pins & input_new &
			     drv_data->interrupts.edge_rising);
		trig_edge |= (changed_pins & input_cache &
			      drv_data->interrupts.edge_falling);
		trig_level = (input_new & drv_data->interrupts.level_high);
		trig_level |= (~input_new & drv_data->interrupts.level_low);

		triggered_int = (trig_edge | trig_level);
	}

	k_sem_give(&drv_data->lock);

	if (triggered_int != 0) {
		gpio_fire_callbacks(&drv_data->callbacks, drv_data->instance,
				    triggered_int);
	}

	/* Emulate level triggering */
	if (trig_level != 0) {
		/* Reschedule worker */
		k_work_submit(&drv_data->interrupt_worker);
	}
}

static void gpio_pca95xx_interrupt_callback(const struct device *dev,
					    struct gpio_callback *cb,
					    gpio_port_pins_t pins)
{
	struct gpio_pca95xx_drv_data * const drv_data =
		CONTAINER_OF(cb, struct gpio_pca95xx_drv_data, gpio_callback);

	ARG_UNUSED(pins);

	/* Cannot read PCA95xx registers from ISR context, queue worker */
	k_work_submit(&drv_data->interrupt_worker);
}
#endif /* CONFIG_GPIO_PCA95XX_INTERRUPT */

static int gpio_pca95xx_pin_interrupt_configure(const struct device *dev,
						  gpio_pin_t pin,
						  enum gpio_int_mode mode,
						  enum gpio_int_trig trig)
{
	int ret = 0;

	if (!IS_ENABLED(CONFIG_GPIO_PCA95XX_INTERRUPT)
	    && (mode != GPIO_INT_MODE_DISABLED)) {
		return -ENOTSUP;
	}

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
	const struct gpio_pca95xx_config * const config = dev->config;
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;
	uint16_t reg;
	bool enabled, edge, level, active;

	/* Check if GPIO port supports interrupts */
	if ((config->capabilities & PCA_HAS_INTERRUPT) == 0U) {
		return -ENOTSUP;
	}

	/* Check for an invalid pin number */
	if (BIT(pin) > config->common.port_pin_mask) {
		return -EINVAL;
	}

	/* Check configured pin direction */
	if ((mode != GPIO_INT_MODE_DISABLED) &&
	    (BIT(pin) & drv_data->reg_cache.dir) != BIT(pin)) {
		LOG_ERR("PCA95XX[0x%X]: output pin cannot trigger interrupt",
			config->bus.addr);
		return -ENOTSUP;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	/* Check if GPIO port has an interrupt mask register */
	if (config->capabilities & PCA_HAS_INTERRUPT_MASK_REG) {
		uint16_t reg_out;

		reg_out = drv_data->reg_cache.int_mask;
		WRITE_BIT(reg_out, pin, (mode == GPIO_INT_MODE_DISABLED));

		ret = update_int_mask_regs(dev, reg_out);
		if (ret != 0) {
			LOG_ERR("PCA95XX[0x%X]: failed to update int mask (%d)",
				config->bus.addr, ret);
			goto err;
		}
	}

	/* Update interrupt masks */
	enabled = ((mode & GPIO_INT_MODE_DISABLED) == 0U);
	edge = (mode == GPIO_INT_MODE_EDGE);
	level = (mode == GPIO_INT_MODE_LEVEL);
	WRITE_BIT(drv_data->interrupts.edge_rising, pin, (enabled &&
		edge && ((trig & GPIO_INT_TRIG_HIGH) == GPIO_INT_TRIG_HIGH)));
	WRITE_BIT(drv_data->interrupts.edge_falling, pin, (enabled &&
		edge && ((trig & GPIO_INT_TRIG_LOW) == GPIO_INT_TRIG_LOW)));
	WRITE_BIT(drv_data->interrupts.level_high, pin, (enabled &&
		level && ((trig & GPIO_INT_TRIG_HIGH) == GPIO_INT_TRIG_HIGH)));
	WRITE_BIT(drv_data->interrupts.level_low, pin, (enabled &&
		level && ((trig & GPIO_INT_TRIG_LOW) == GPIO_INT_TRIG_LOW)));

	active = ((drv_data->interrupts.edge_rising ||
		   drv_data->interrupts.edge_falling ||
		   drv_data->interrupts.level_high ||
		   drv_data->interrupts.level_low) > 0);

	/* Enable / disable interrupt as needed */
	if (active != drv_data->interrupt_active) {
		ret = gpio_pin_interrupt_configure_dt(
			&config->int_gpio, active ?
				   GPIO_INT_EDGE_TO_ACTIVE :
				   GPIO_INT_MODE_DISABLED);
		if (ret != 0) {
			LOG_ERR("PCA95XX[0x%X]: failed to configure interrupt "
				"on pin %d (%d)", config->bus.addr,
				config->int_gpio.pin, ret);
			goto err;
		}
		drv_data->interrupt_active = active;

		if (active) {
			/* Read current status to reset any
			 * active signal on INT line
			 */
			update_input_regs(dev, &reg);
		}
	}

err:
	k_sem_give(&drv_data->lock);
#endif /* CONFIG_GPIO_PCA95XX_INTERRUPT */
	return ret;
}

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
static int gpio_pca95xx_manage_callback(const struct device *dev,
					struct gpio_callback *callback,
					bool set)
{
	const struct gpio_pca95xx_config * const config = dev->config;
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	if ((config->capabilities & PCA_HAS_INTERRUPT) == 0U) {
		return -ENOTSUP;
	}

	k_sem_take(&drv_data->lock, K_FOREVER);

	gpio_manage_callback(&drv_data->callbacks, callback, set);

	k_sem_give(&drv_data->lock);
	return 0;
}
#endif

static const struct gpio_driver_api gpio_pca95xx_drv_api_funcs = {
	.pin_configure = gpio_pca95xx_config,
	.port_get_raw = gpio_pca95xx_port_get_raw,
	.port_set_masked_raw = gpio_pca95xx_port_set_masked_raw,
	.port_set_bits_raw = gpio_pca95xx_port_set_bits_raw,
	.port_clear_bits_raw = gpio_pca95xx_port_clear_bits_raw,
	.port_toggle_bits = gpio_pca95xx_port_toggle_bits,
	.pin_interrupt_configure = gpio_pca95xx_pin_interrupt_configure,
#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
	.manage_callback = gpio_pca95xx_manage_callback,
#endif
};

/**
 * @brief Initialization function of PCA95XX
 *
 * @param dev Device struct
 * @return 0 if successful, failed otherwise.
 */
static int gpio_pca95xx_init(const struct device *dev)
{
	const struct gpio_pca95xx_config * const config = dev->config;
	struct gpio_pca95xx_drv_data * const drv_data =
		(struct gpio_pca95xx_drv_data * const)dev->data;

	if (!device_is_ready(config->bus.bus)) {
		return -ENODEV;
	}

	k_sem_init(&drv_data->lock, 1, 1);

#ifdef CONFIG_GPIO_PCA95XX_INTERRUPT
	/* Check if GPIO port supports interrupts */
	if ((config->capabilities & PCA_HAS_INTERRUPT) != 0) {
		int ret;

		/* Store self-reference for interrupt handling */
		drv_data->instance = dev;

		/* Prepare interrupt worker */
		k_work_init(&drv_data->interrupt_worker,
			    gpio_pca95xx_interrupt_worker);

		/* Configure GPIO interrupt pin */
		if (!device_is_ready(config->int_gpio.port)) {
			LOG_ERR("PCA95XX[0x%X]: interrupt GPIO not ready",
				config->bus.addr);
			return -ENODEV;
		}

		ret = gpio_pin_configure_dt(&config->int_gpio, GPIO_INPUT);
		if (ret != 0) {
			LOG_ERR("PCA95XX[0x%X]: failed to configure interrupt"
				" pin %d (%d)", config->bus.addr,
				config->int_gpio.pin, ret);
			return ret;
		}

		/* Prepare GPIO callback for interrupt pin */
		gpio_init_callback(&drv_data->gpio_callback,
				   gpio_pca95xx_interrupt_callback,
				   BIT(config->int_gpio.pin));
		gpio_add_callback(config->int_gpio.port, &drv_data->gpio_callback);
	}
#endif

	return 0;
}

#define GPIO_PCA95XX_DEVICE_INSTANCE(inst)				\
static const struct gpio_pca95xx_config gpio_pca95xx_##inst##_cfg = {	\
	.common = {							\
		.port_pin_mask = GPIO_PORT_PIN_MASK_FROM_DT_INST(inst),	\
	},								\
	.bus = I2C_DT_SPEC_INST_GET(inst),				\
	.capabilities =							\
		(DT_INST_PROP(inst, has_pud) ? PCA_HAS_PUD : 0) |	\
		IF_ENABLED(CONFIG_GPIO_PCA95XX_INTERRUPT, (		\
		(DT_INST_NODE_HAS_PROP(inst, interrupt_gpios) ?		\
			PCA_HAS_INTERRUPT : 0) |			\
		(DT_INST_PROP(inst, has_interrupt_mask_reg) ?		\
			PCA_HAS_INTERRUPT_MASK_REG : 0) |		\
		))							\
		0,							\
	IF_ENABLED(CONFIG_GPIO_PCA95XX_INTERRUPT,			\
	(.int_gpio = GPIO_DT_SPEC_INST_GET_OR(inst, interrupt_gpios, {}),)) \
};									\
									\
static struct gpio_pca95xx_drv_data gpio_pca95xx_##inst##_drvdata = {	\
	.reg_cache.input = 0x0,						\
	.reg_cache.output = 0xFFFF,					\
	.reg_cache.dir = 0xFFFF,					\
	.reg_cache.pud_en = 0x0,					\
	.reg_cache.pud_sel = 0xFFFF,					\
	IF_ENABLED(CONFIG_GPIO_PCA95XX_INTERRUPT, (			\
	.interrupt_active = false,					\
	))								\
};									\
									\
DEVICE_DT_INST_DEFINE(inst,						\
	gpio_pca95xx_init,						\
	NULL,								\
	&gpio_pca95xx_##inst##_drvdata,					\
	&gpio_pca95xx_##inst##_cfg,					\
	POST_KERNEL, CONFIG_GPIO_PCA95XX_INIT_PRIORITY,			\
	&gpio_pca95xx_drv_api_funcs);

DT_INST_FOREACH_STATUS_OKAY(GPIO_PCA95XX_DEVICE_INSTANCE)


text:
#include "ClientUDP.h"

edk::network::udp::ClientUDP::ClientUDP()
{
    this->cleanAdress();
}
edk::network::udp::ClientUDP::~ClientUDP(){
    this->cleanAdress();
    this->closeSocket();
}

//close the socket
void edk::network::udp::ClientUDP::closeSocket(){
    edk::network::Socket::closeSocket();
}

//Send a message to the server
edk::int32 edk::network::udp::ClientUDP::sendStream(edk::network::Adress host,edk::classID stream,edk::uint32 size){
    //test the host stream and size
    if(host.getIP() && host.getPort() && stream && size){
        //test if dont have the socket
        if(!this->haveSocket()){
            //create the socket
            if(!this->createSocket(EDK_SOCKET_UDP)){
                //else return false
                return false;
            }
        }
        //else send the stream
        if(this->haveSocket()){
            //test if the adress is diferent than the last adress
            if(this->sendHost!=host){
                //create a new host
                this->sendHost = host;
                this->loadNewSendAdress(this->sendHost.getIP());
                this->sockAdress.sin_port = htons(this->sendHost.getPort());
            }
            //then send the message
            return edk::network::Socket::sendStreamTo(this->getSocket(),this->sockAdress,stream,size);
        }
    }
    return false;
}
edk::int32 edk::network::udp::ClientUDP::sendStream(edk::network::Adress host,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStream(host,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(edk::network::Adress host,edk::classID stream,edk::uint32 size){
    //test the host stream and size
    if(host.getIP() && host.getPort() && stream && size){
        //test if dont have the socket
        if(!this->haveSocket()){
            //create the socket
            if(!this->createSocket(EDK_SOCKET_UDP)){
                //else return false
                return false;
            }
        }
        //else send the stream
        if(this->haveSocket()){
            //test if the adress is diferent than the last adress
            if(this->sendHost!=host){
                //create a new host
                this->sendHost = host;
                this->loadNewSendAdress(this->sendHost.getIP());
                this->sockAdress.sin_port = htons(this->sendHost.getPort());
            }
            //then send the message
            return edk::network::Socket::sendStreamToNonBlock(this->getSocket(),this->sockAdress,stream,size);
        }
    }
    return false;
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(edk::network::Adress host,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStreamNonBlock(host,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendString(edk::network::Adress host,edk::char8* string){
    return this->sendStream(host,string,edk::String::strSize(string)+1u);
}
edk::int32 edk::network::udp::ClientUDP::sendString(edk::network::Adress host,const edk::char8* string){
    return this->sendString(host,(edk::char8*)string);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(edk::network::Adress host,edk::char8* string){
    return this->sendStreamNonBlock(host,string,edk::String::strSize(string)+1u);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(edk::network::Adress host,const edk::char8* string){
    return this->sendStringNonBlock(host,(edk::char8*)string);
}
edk::int32 edk::network::udp::ClientUDP::sendStream(edk::char8* ip,edk::uint16 port,edk::classID stream,edk::uint32 size){
    return edk::network::Socket::sendStream(ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStream(const edk::char8* ip,edk::uint16 port,edk::classID stream,edk::uint32 size){
    return edk::network::Socket::sendStream((edk::char8*)ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStream(edk::char8* ip,edk::uint16 port,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStream(ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStream(const edk::char8* ip,edk::uint16 port,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStream((edk::char8*)ip,port,(void*)stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(edk::char8* ip,edk::uint16 port,edk::classID stream,edk::uint32 size){
    return edk::network::Socket::sendStreamNonBlock(ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(const edk::char8* ip,edk::uint16 port,edk::classID stream,edk::uint32 size){
    return edk::network::Socket::sendStreamNonBlock((edk::char8*)ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(edk::char8* ip,edk::uint16 port,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStreamNonBlock(ip,port,stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendStreamNonBlock(const edk::char8* ip,edk::uint16 port,const void* stream,edk::uint32 size){
    return edk::network::Socket::sendStreamNonBlock((edk::char8*)ip,port,(void*)stream,size);
}
edk::int32 edk::network::udp::ClientUDP::sendString(edk::char8* ip,edk::uint16 port,edk::char8* string){
    return this->sendStream(ip,port,string,edk::String::strSize(string)+1u);
}
edk::int32 edk::network::udp::ClientUDP::sendString(const edk::char8* ip,edk::uint16 port,edk::char8* string){
    return this->sendString((edk::char8* )ip,port,string);
}
edk::int32 edk::network::udp::ClientUDP::sendString(edk::char8* ip,edk::uint16 port,const edk::char8* string){
    return this->sendString(ip,port,(edk::char8* )string);
}
edk::int32 edk::network::udp::ClientUDP::sendString(const edk::char8* ip,edk::uint16 port,const edk::char8* string){
    return this->sendString((edk::char8* )ip,port,(edk::char8* )string);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(edk::char8* ip,edk::uint16 port,edk::char8* string){
    return this->sendStreamNonBlock(ip,port,string,edk::String::strSize(string)+1u);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(const edk::char8* ip,edk::uint16 port,edk::char8* string){
    return this->sendStringNonBlock((edk::char8* )ip,port,string);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(edk::char8* ip,edk::uint16 port,const edk::char8* string){
    return this->sendStringNonBlock(ip,port,(edk::char8* )string);
}
edk::int32 edk::network::udp::ClientUDP::sendStringNonBlock(const edk::char8* ip,edk::uint16 port,const edk::char8* string){
    return this->sendStringNonBlock((edk::char8* )ip,port,(edk::char8* )string);
}
//Receive the message
edk::int32 edk::network::udp::ClientUDP::receiveStream(edk::classID stream,edk::uint32 size,edk::network::Adress* host){
    //test the host, sream and size
    if(host && stream && size){
        //recebe a mensagem
        struct sockaddr_in adress;
        edk::network::Socket::cleanAdress(&adress);
        edk::int32 ret = edk::network::Socket::receiveStreamFrom(this->getSocket(),&adress,stream,size);
        //carrega o IP
        host->setIP(edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,0u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,1u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,2u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,3u)
                    );
        host->setPort(adress.sin_port);
        return ret;
    }
    //senao retorna 0u
    return 0u;
}
edk::int32 edk::network::udp::ClientUDP::receiveStreamNonBlock(edk::classID stream,edk::uint32 size,edk::network::Adress* host){
    //test the host, sream and size
    if(host && stream && size){
        //recebe a mensagem
        struct sockaddr_in adress;
        edk::network::Socket::cleanAdress(&adress);
        edk::int32 ret = edk::network::Socket::receiveStreamFromNonBlock(this->getSocket(),&adress,stream,size);
        //carrega o IP
        host->setIP(edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,0u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,1u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,2u),
                    edk::network::Adress::getIpNumber(adress.sin_addr.s_addr,3u)
                    );
        host->setPort(adress.sin_port);
        return ret;
    }
    //senao retorna 0u
    return 0u;
}

//Carrega o novo endereco
void edk::network::udp::ClientUDP::loadNewSendAdress(edk::uint32 ip){
    //this->cleanAdress(&this->myAdress);
    this->sockAdress = this->getAdress(ip);
}
void edk::network::udp::ClientUDP::loadNewSendAdress(edk::char8* ip){
    //
    //this->cleanAdress(&this->myAdress);
    this->sockAdress = this->getAdress(ip);
}

redpajama_set_name: RedPajamaGithub


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

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

        #region Windows Form Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.components = new System.ComponentModel.Container();
            this.sc2HostFetchTimer = new System.Windows.Forms.Timer(this.components);
            this.webBrowserOutput = new System.Windows.Forms.WebBrowser();
            this.SuspendLayout();
            //
            // sc2HostFetchTimer
            //
            this.sc2HostFetchTimer.Interval = 2000;
            this.sc2HostFetchTimer.Tick += new System.EventHandler(this.OnTimerTick);
            //
            // webBrowserOutput
            //
            this.webBrowserOutput.Dock = System.Windows.Forms.DockStyle.Fill;
            this.webBrowserOutput.Location = new System.Drawing.Point(0, 0);
            this.webBrowserOutput.MinimumSize = new System.Drawing.Size(20, 20);
            this.webBrowserOutput.Name = "webBrowserOutput";
            this.webBrowserOutput.ScrollBarsEnabled = false;
            this.webBrowserOutput.Size = new System.Drawing.Size(909, 171);
            this.webBrowserOutput.TabIndex = 0;
            //
            // FormOutput
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.BackColor = System.Drawing.Color.Black;
            this.ClientSize = new System.Drawing.Size(909, 171);
            this.Controls.Add(this.webBrowserOutput);
            this.ForeColor = System.Drawing.Color.White;
            this.Name = "FormOutput";
            this.Text = "Output - Sc2StreamChatAssistant";
            this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.OnFormClosing);
            this.ResumeLayout(false);

        }

        #endregion

        private System.Windows.Forms.Timer sc2HostFetchTimer;
        private System.Windows.Forms.WebBrowser webBrowserOutput;
    }
}


text:
package org.apache.batik.svggen;

import java.awt.GradientPaint;
import java.awt.Paint;
import java.awt.geom.Point2D;

import org.apache.batik.ext.awt.g2d.GraphicContext;
import org.w3c.dom.Document;
import org.w3c.dom.Element;

/**
 * Utility class that converts a Java GradientPaint into an
 * SVG linear gradient element
 *
 * @author Vincent Hardy
 * @version $Id: SVGLinearGradient.java 475477 2006-11-15 22:44:28Z cam $
 */
public class SVGLinearGradient extends AbstractSVGConverter {
    /**
     * @param generatorContext used to build Elements
     */
    public SVGLinearGradient(SVGGeneratorContext generatorContext) {
        super(generatorContext);
    }

    /**
     * Converts part or all of the input GraphicContext into
     * a set of attribute/value pairs and related definitions
     *
     * @param gc GraphicContext to be converted
     * @return descriptor of the attributes required to represent
     *         some or all of the GraphicContext state, along
     *         with the related definitions
     * @see org.apache.batik.svggen.SVGDescriptor
     */
    public SVGDescriptor toSVG(GraphicContext gc) {
        Paint paint = gc.getPaint();
        return toSVG((GradientPaint)paint);
    }

    /**
     * @param gradient the GradientPaint to be converted
     * @return a description of the SVG paint and opacity corresponding
     *         to the gradient Paint. The definiton of the
     *         linearGradient is put in the linearGradientDefsMap
     */
    public SVGPaintDescriptor toSVG(GradientPaint gradient) {
        // Reuse definition if gradient has already been converted
        SVGPaintDescriptor gradientDesc =
            (SVGPaintDescriptor)descMap.get(gradient);

        Document domFactory = generatorContext.domFactory;

        if (gradientDesc == null) {
            Element gradientDef =
                domFactory.createElementNS(SVG_NAMESPACE_URI,
                                           SVG_LINEAR_GRADIENT_TAG);
            gradientDef.setAttributeNS(null, SVG_GRADIENT_UNITS_ATTRIBUTE,
                                       SVG_USER_SPACE_ON_USE_VALUE);

            //
            // Process gradient vector
            //
            Point2D p1 = gradient.getPoint1();
            Point2D p2 = gradient.getPoint2();
            gradientDef.setAttributeNS(null, SVG_X1_ATTRIBUTE,
                                       doubleString(p1.getX()));
            gradientDef.setAttributeNS(null, SVG_Y1_ATTRIBUTE,
                                       doubleString(p1.getY()));
            gradientDef.setAttributeNS(null, SVG_X2_ATTRIBUTE,
                                       doubleString(p2.getX()));
            gradientDef.setAttributeNS(null, SVG_Y2_ATTRIBUTE,
                                       doubleString(p2.getY()));

            //
            // Spread method
            //
            String spreadMethod = SVG_PAD_VALUE;
            if(gradient.isCyclic())
                spreadMethod = SVG_REFLECT_VALUE;
            gradientDef.setAttributeNS
                (null, SVG_SPREAD_METHOD_ATTRIBUTE, spreadMethod);

            //
            // First gradient stop
            //
            Element gradientStop =
                domFactory.createElementNS(SVG_NAMESPACE_URI, SVG_STOP_TAG);
            gradientStop.setAttributeNS(null, SVG_OFFSET_ATTRIBUTE,
                                      SVG_ZERO_PERCENT_VALUE);

            SVGPaintDescriptor colorDesc = SVGColor.toSVG(gradient.getColor1(), generatorContext);
            gradientStop.setAttributeNS(null, SVG_STOP_COLOR_ATTRIBUTE,
                                      colorDesc.getPaintValue());
            gradientStop.setAttributeNS(null, SVG_STOP_OPACITY_ATTRIBUTE,
                                      colorDesc.getOpacityValue());

            gradientDef.appendChild(gradientStop);

            //
            // Second gradient stop
            //
            gradientStop =
                domFactory.createElementNS(SVG_NAMESPACE_URI, SVG_STOP_TAG);
            gradientStop.setAttributeNS(null, SVG_OFFSET_ATTRIBUTE,
                                      SVG_HUNDRED_PERCENT_VALUE);

            colorDesc = SVGColor.toSVG(gradient.getColor2(), generatorContext);
            gradientStop.setAttributeNS(null, SVG_STOP_COLOR_ATTRIBUTE,
                                        colorDesc.getPaintValue());
            gradientStop.setAttributeNS(null, SVG_STOP_OPACITY_ATTRIBUTE,
                                        colorDesc.getOpacityValue());

            gradientDef.appendChild(gradientStop);

            //
            // Gradient ID
            //
            gradientDef.
                setAttributeNS(null, SVG_ID_ATTRIBUTE,
                               generatorContext.idGenerator.
                               generateID(ID_PREFIX_LINEAR_GRADIENT));

            //
            // Build Paint descriptor
            //
            StringBuffer paintAttrBuf = new StringBuffer(URL_PREFIX);
            paintAttrBuf.append(SIGN_POUND);
            paintAttrBuf.append(gradientDef.getAttributeNS(null, SVG_ID_ATTRIBUTE));
            paintAttrBuf.append(URL_SUFFIX);

            gradientDesc = new SVGPaintDescriptor(paintAttrBuf.toString(),
                                                  SVG_OPAQUE_VALUE,
                                                  gradientDef);

            //
            // Update maps so that gradient can be reused if needed
            //
            descMap.put(gradient, gradientDesc);
            defSet.add(gradientDef);
        }

        return gradientDesc;
    }
}


text:
package com.thoughtworks.studios.mingle.hg.cmdline;

import java.io.OutputStreamWriter;

public class TestProgram {

  public static String[] cmdFor(String[] args) {
    String[] cmd = new String[args.length + 4];
    cmd[0] = "java";
    cmd[1] = "-cp";
    cmd[2] = System.getProperty("java.class.path");
    cmd[3] = TestProgram.class.getName();
    for (int i = 4; i < cmd.length; i++) {
      cmd[i] = args[i - 4];
    }
    return cmd;
  }

  public static void main(String[] args) throws Exception {
    if (args[0].equals("sleep")) {
      Thread.sleep(Integer.valueOf(args[1]));
    } else if (args[0].equals("echo")) {
      OutputStreamWriter writer = new OutputStreamWriter(System.out, "UTF-8");
      writer.write(args[1]);
      writer.flush();
    } else if (args[0].equals("error")) {
      OutputStreamWriter writer = new OutputStreamWriter(System.err, "UTF-8");
      writer.write(args[1]);
      writer.flush();
      System.exit(Integer.valueOf(args[2]));
    } else if (args[0].equals("chinese")) {
	  OutputStreamWriter writer = new OutputStreamWriter(System.out, "UTF-8");
      writer.write("这是中文");
      writer.flush();
	}
  }
}


text:
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="ChangeListManager">
    <list default="true" id="118ccca8-e127-4358-8a05-ef3de6bb1661" name="Default" comment="" />
    <ignored path="webometrics-parser.iws" />
    <ignored path=".idea/workspace.xml" />
    <ignored path="$PROJECT_DIR$/out/" />
    <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
    <option name="TRACKING_ENABLED" value="true" />
    <option name="SHOW_DIALOG" value="false" />
    <option name="HIGHLIGHT_CONFLICTS" value="true" />
    <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
    <option name="LAST_RESOLUTION" value="IGNORE" />
  </component>
  <component name="ChangesViewManager" flattened_view="true" show_ignored="false" />
  <component name="CreatePatchCommitExecutor">
    <option name="PATCH_PATH" value="" />
  </component>
  <component name="ExecutionTargetManager" SELECTED_TARGET="default_target" />
  <component name="FavoritesManager">
    <favorites_list name="webometrics-parser" />
  </component>
  <component name="FileEditorManager">
    <leaf SIDE_TABS_SIZE_LIMIT_KEY="300" />
  </component>
  <component name="FileTemplateManagerImpl">
    <option name="RECENT_TEMPLATES">
      <list>
        <option value="Class" />
      </list>
    </option>
  </component>
  <component name="GradleLocalSettings">
    <option name="externalProjectsViewState">
      <projects_view />
    </option>
  </component>
  <component name="IdeDocumentHistory">
    <option name="CHANGED_PATHS">
      <list>
        <option value="$PROJECT_DIR$/src/com/github/lassana/wmparser/UniversityInfo.java" />
        <option value="$PROJECT_DIR$/resources/log4j.properties" />
        <option value="$PROJECT_DIR$/webometrics.log" />
        <option value="$PROJECT_DIR$/src/com/github/lassana/wmparser/Main.java" />
        <option value="$PROJECT_DIR$/src/com/github/lassana/wmparser/WebometricsParser.java" />
        <option value="$PROJECT_DIR$/src/com/github/lassana/wmparser/ExcelOutputter.java" />
      </list>
    </option>
  </component>
  <component name="MavenImportPreferences">
    <option name="generalSettings">
      <MavenGeneralSettings>
        <option name="mavenHome" value="Bundled (Maven 3)" />
      </MavenGeneralSettings>
    </option>
  </component>
  <component name="ProjectFrameBounds">
    <option name="x" value="136" />
    <option name="y" value="46" />
    <option name="width" value="1400" />
    <option name="height" value="837" />
  </component>
  <component name="ProjectLevelVcsManager" settingsEditedManually="false">
    <OptionsSetting value="true" id="Add" />
    <OptionsSetting value="true" id="Remove" />
    <OptionsSetting value="true" id="Checkout" />
    <OptionsSetting value="true" id="Update" />
    <OptionsSetting value="true" id="Status" />
    <OptionsSetting value="true" id="Edit" />
    <ConfirmationsSetting value="0" id="Add" />
    <ConfirmationsSetting value="0" id="Remove" />
  </component>
  <component name="ProjectView">
    <navigator currentView="ProjectPane" proportions="" version="1">
      <flattenPackages />
      <showMembers />
      <showModules />
      <showLibraryContents />
      <hideEmptyPackages />
      <abbreviatePackageNames />
      <autoscrollToSource />
      <autoscrollFromSource />
      <sortByType />
      <manualOrder />
      <foldersAlwaysOnTop value="true" />
    </navigator>
    <panes>
      <pane id="Scope" />
      <pane id="ProjectPane">
        <subPane>
          <PATH>
            <PATH_ELEMENT>
              <option name="myItemId" value="webometrics-parser" />
              <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
            </PATH_ELEMENT>
          </PATH>
          <PATH>
            <PATH_ELEMENT>
              <option name="myItemId" value="webometrics-parser" />
              <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
            </PATH_ELEMENT>
            <PATH_ELEMENT>
              <option name="myItemId" value="webometrics-parser" />
              <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
            </PATH_ELEMENT>
          </PATH>
        </subPane>
      </pane>
      <pane id="PackagesPane" />
      <pane id="Scratches" />
    </panes>
  </component>
  <component name="PropertiesComponent">
    <property name="Downloaded.Files.Path.Enabled" value="false" />
    <property name="Repository.Attach.JavaDocs" value="false" />
    <property name="Repository.Attach.Sources" value="false" />
    <property name="project.structure.last.edited" value="Modules" />
    <property name="project.structure.proportion" value="0.15" />
    <property name="project.structure.side.proportion" value="0.2" />
  </component>
  <component name="RunManager" selected="Application.Main">
    <configuration default="false" name="Main" type="Application" factoryName="Application" temporary="true">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <option name="MAIN_CLASS_NAME" value="com.github.lassana.wmparser.Main" />
      <option name="VM_PARAMETERS" value="" />
      <option name="PROGRAM_PARAMETERS" value="" />
      <option name="WORKING_DIRECTORY" value="file://$PROJECT_DIR$" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" value="" />
      <option name="ENABLE_SWING_INSPECTOR" value="false" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <module name="webometrics-parser" />
      <envs />
      <RunnerSettings RunnerId="Run" />
      <ConfigurationWrapper RunnerId="Run" />
      <method />
    </configuration>
    <configuration default="true" type="AndroidRunConfigurationType" factoryName="Android Application">
      <module name="" />
      <option name="ACTIVITY_CLASS" value="" />
      <option name="MODE" value="default_activity" />
      <option name="DEPLOY" value="true" />
      <option name="ARTIFACT_NAME" value="" />
      <option name="TARGET_SELECTION_MODE" value="EMULATOR" />
      <option name="USE_LAST_SELECTED_DEVICE" value="false" />
      <option name="PREFERRED_AVD" value="" />
      <option name="USE_COMMAND_LINE" value="true" />
      <option name="COMMAND_LINE" value="" />
      <option name="WIPE_USER_DATA" value="false" />
      <option name="DISABLE_BOOT_ANIMATION" value="false" />
      <option name="NETWORK_SPEED" value="full" />
      <option name="NETWORK_LATENCY" value="none" />
      <option name="CLEAR_LOGCAT" value="false" />
      <option name="SHOW_LOGCAT_AUTOMATICALLY" value="true" />
      <option name="FILTER_LOGCAT_AUTOMATICALLY" value="true" />
      <option name="SELECTED_CLOUD_MATRIX_CONFIGURATION_ID" value="0" />
      <option name="SELECTED_CLOUD_MATRIX_PROJECT_ID" value="" />
      <option name="SELECTED_CLOUD_DEVICE_CONFIGURATION_ID" value="0" />
      <option name="SELECTED_CLOUD_DEVICE_PROJECT_ID" value="" />
      <option name="IS_VALID_CLOUD_MATRIX_SELECTION" value="false" />
      <option name="INVALID_CLOUD_MATRIX_SELECTION_ERROR" value="" />
      <option name="IS_VALID_CLOUD_DEVICE_SELECTION" value="false" />
      <option name="INVALID_CLOUD_DEVICE_SELECTION_ERROR" value="" />
      <option name="CLOUD_DEVICE_SERIAL_NUMBER" value="" />
      <method />
    </configuration>
    <configuration default="true" type="AndroidTestRunConfigurationType" factoryName="Android Tests">
      <module name="" />
      <option name="TESTING_TYPE" value="0" />
      <option name="INSTRUMENTATION_RUNNER_CLASS" value="" />
      <option name="METHOD_NAME" value="" />
      <option name="CLASS_NAME" value="" />
      <option name="PACKAGE_NAME" value="" />
      <option name="TARGET_SELECTION_MODE" value="EMULATOR" />
      <option name="USE_LAST_SELECTED_DEVICE" value="false" />
      <option name="PREFERRED_AVD" value="" />
      <option name="USE_COMMAND_LINE" value="true" />
      <option name="COMMAND_LINE" value="" />
      <option name="WIPE_USER_DATA" value="false" />
      <option name="DISABLE_BOOT_ANIMATION" value="false" />
      <option name="NETWORK_SPEED" value="full" />
      <option name="NETWORK_LATENCY" value="none" />
      <option name="CLEAR_LOGCAT" value="false" />
      <option name="SHOW_LOGCAT_AUTOMATICALLY" value="true" />
      <option name="FILTER_LOGCAT_AUTOMATICALLY" value="true" />
      <option name="SELECTED_CLOUD_MATRIX_CONFIGURATION_ID" value="0" />
      <option name="SELECTED_CLOUD_MATRIX_PROJECT_ID" value="" />
      <option name="SELECTED_CLOUD_DEVICE_CONFIGURATION_ID" value="0" />
      <option name="SELECTED_CLOUD_DEVICE_PROJECT_ID" value="" />
      <option name="IS_VALID_CLOUD_MATRIX_SELECTION" value="false" />
      <option name="INVALID_CLOUD_MATRIX_SELECTION_ERROR" value="" />
      <option name="IS_VALID_CLOUD_DEVICE_SELECTION" value="false" />
      <option name="INVALID_CLOUD_DEVICE_SELECTION_ERROR" value="" />
      <option name="CLOUD_DEVICE_SERIAL_NUMBER" value="" />
      <method />
    </configuration>
    <configuration default="true" type="Application" factoryName="Application">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <option name="MAIN_CLASS_NAME" />
      <option name="VM_PARAMETERS" />
      <option name="PROGRAM_PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="ENABLE_SWING_INSPECTOR" value="false" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <module name="" />
      <envs />
      <method />
    </configuration>
    <configuration default="true" type="GradleRunConfiguration" factoryName="Gradle">
      <ExternalSystemSettings>
        <option name="executionName" />
        <option name="externalProjectPath" />
        <option name="externalSystemIdString" value="GRADLE" />
        <option name="scriptParameters" />
        <option name="taskDescriptions">
          <list />
        </option>
        <option name="taskNames">
          <list />
        </option>
        <option name="vmOptions" />
      </ExternalSystemSettings>
      <method />
    </configuration>
    <configuration default="true" type="JUnit" factoryName="JUnit">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <module name="" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="PACKAGE_NAME" />
      <option name="MAIN_CLASS_NAME" />
      <option name="METHOD_NAME" />
      <option name="TEST_OBJECT" value="class" />
      <option name="VM_PARAMETERS" />
      <option name="PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <option name="TEST_SEARCH_SCOPE">
        <value defaultName="singleModule" />
      </option>
      <envs />
      <patterns />
      <method />
    </configuration>
    <configuration default="true" type="JUnitTestDiscovery" factoryName="JUnit Test Discovery" changeList="All">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <module name="" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="PACKAGE_NAME" />
      <option name="MAIN_CLASS_NAME" />
      <option name="METHOD_NAME" />
      <option name="TEST_OBJECT" value="class" />
      <option name="VM_PARAMETERS" />
      <option name="PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <option name="TEST_SEARCH_SCOPE">
        <value defaultName="singleModule" />
      </option>
      <envs />
      <patterns />
      <method />
    </configuration>
    <configuration default="true" type="JarApplication" factoryName="JAR Application">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <envs />
      <method />
    </configuration>
    <configuration default="true" type="Java Scratch" factoryName="Java Scratch">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <option name="SCRATCH_FILE_ID" value="0" />
      <option name="MAIN_CLASS_NAME" />
      <option name="VM_PARAMETERS" />
      <option name="PROGRAM_PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="ENABLE_SWING_INSPECTOR" value="false" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <module name="" />
      <envs />
      <method />
    </configuration>
    <configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <option name="MAIN_CLASS_NAME" />
      <option name="VM_PARAMETERS" />
      <option name="PROGRAM_PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <module name="webometrics-parser" />
      <envs />
      <method />
    </configuration>
    <configuration default="true" type="KotlinStandaloneScriptRunConfigurationType" factoryName="Kotlin script">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <option name="filePath" />
      <option name="vmParameters" />
      <option name="alternativeJrePath" />
      <option name="programParameters" />
      <option name="passParentEnvs" value="true" />
      <option name="workingDirectory" />
      <option name="isAlternativeJrePathEnabled" value="false" />
      <envs />
      <method />
    </configuration>
    <configuration default="true" type="TestNG" factoryName="TestNG">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <module name="" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="SUITE_NAME" />
      <option name="PACKAGE_NAME" />
      <option name="MAIN_CLASS_NAME" />
      <option name="METHOD_NAME" />
      <option name="GROUP_NAME" />
      <option name="TEST_OBJECT" value="CLASS" />
      <option name="VM_PARAMETERS" />
      <option name="PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="OUTPUT_DIRECTORY" />
      <option name="ANNOTATION_TYPE" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <option name="TEST_SEARCH_SCOPE">
        <value defaultName="singleModule" />
      </option>
      <option name="USE_DEFAULT_REPORTERS" value="false" />
      <option name="PROPERTIES_FILE" />
      <envs />
      <properties />
      <listeners />
      <method />
    </configuration>
    <configuration default="true" type="TestNGTestDiscovery" factoryName="TestNG Test Discovery" changeList="All">
      <extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
      <module name="" />
      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
      <option name="ALTERNATIVE_JRE_PATH" />
      <option name="SUITE_NAME" />
      <option name="PACKAGE_NAME" />
      <option name="MAIN_CLASS_NAME" />
      <option name="METHOD_NAME" />
      <option name="GROUP_NAME" />
      <option name="TEST_OBJECT" value="CLASS" />
      <option name="VM_PARAMETERS" />
      <option name="PARAMETERS" />
      <option name="WORKING_DIRECTORY" />
      <option name="OUTPUT_DIRECTORY" />
      <option name="ANNOTATION_TYPE" />
      <option name="ENV_VARIABLES" />
      <option name="PASS_PARENT_ENVS" value="true" />
      <option name="TEST_SEARCH_SCOPE">
        <value defaultName="singleModule" />
      </option>
      <option name="USE_DEFAULT_REPORTERS" value="false" />
      <option name="PROPERTIES_FILE" />
      <envs />
      <properties />
      <listeners />
      <method />
    </configuration>
    <list size="1">
      <item index="0" class="java.lang.String" itemvalue="Application.Main" />
    </list>
    <recent_temporary>
      <list size="1">
        <item index="0" class="java.lang.String" itemvalue="Application.Main" />
      </list>
    </recent_temporary>
  </component>
  <component name="ShelveChangesManager" show_recycled="false" />
  <component name="TaskManager">
    <task active="true" id="Default" summary="Default task">
      <changelist id="118ccca8-e127-4358-8a05-ef3de6bb1661" name="Default" comment="" />
      <created>1454491563598</created>
      <option name="number" value="Default" />
      <updated>1454491563598</updated>
    </task>
    <servers />
  </component>
  <component name="ToolWindowManager">
    <frame x="136" y="46" width="1400" height="837" extended-state="0" />
    <editor active="false" />
    <layout>
      <window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32885906" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Palette	" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
      <window_info id="Maven Projects" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.5744966" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
      <window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32885906" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Designer" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Project" active="true" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.2496318" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32885906" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
      <window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
      <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
      <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="false" content_ui="tabs" />
      <window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="-1" side_tool="true" content_ui="tabs" />
      <window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
      <window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="4" side_tool="false" content_ui="tabs" />
      <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
      <window_info id="Message" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
      <window_info id="Commander" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
      <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
    </layout>
  </component>
  <component name="VcsContentAnnotationSettings">
    <option name="myLimit" value="2678400000" />
  </component>
  <component name="XDebuggerManager">
    <breakpoint-manager>
      <option name="time" value="5" />
    </breakpoint-manager>
    <watches-manager />
  </component>
  <component name="antWorkspaceConfiguration">
    <option name="IS_AUTOSCROLL_TO_SOURCE" value="false" />
    <option name="FILTER_TARGETS" value="false" />
  </component>
  <component name="editorHistoryManager">
    <entry file="jar://$MAVEN_REPOSITORY$/org/jsoup/jsoup/1.8.3/jsoup-1.8.3.jar!/org/jsoup/Jsoup.class">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.35280898">
          <caret line="36" column="29" selection-start-line="36" selection-start-column="29" selection-end-line="36" selection-end-column="29" />
          <folding>
            <element signature="e#952#953#0" expanded="true" />
            <element signature="e#1002#1003#0" expanded="true" />
          </folding>
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/webometrics.log">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="-0.50358">
          <caret line="27" column="0" selection-start-line="27" selection-start-column="0" selection-end-line="27" selection-end-column="0" />
          <folding />
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/resources/log4j.properties">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.53699285">
          <caret line="15" column="90" selection-start-line="15" selection-start-column="90" selection-end-line="15" selection-end-column="90" />
          <folding />
        </state>
      </provider>
    </entry>
    <entry file="jar://$MAVEN_REPOSITORY$/org/jsoup/jsoup/1.8.3/jsoup-1.8.3.jar!/org/jsoup/Connection.class">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="-5.814815">
          <caret line="22" column="15" selection-start-line="22" selection-start-column="15" selection-end-line="22" selection-end-column="15" />
          <folding />
        </state>
      </provider>
    </entry>
    <entry file="jar://$USER_HOME$/.ideaLibSources/jsoup-1.8.3-sources.jar!/org/jsoup/Connection.java">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.33262712">
          <caret line="258" column="41" selection-start-line="258" selection-start-column="30" selection-end-line="258" selection-end-column="41" />
          <folding />
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/src/com/github/lassana/wmparser/WebometricsParser.java">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.33333334">
          <caret line="49" column="38" selection-start-line="49" selection-start-column="38" selection-end-line="49" selection-end-column="38" />
          <folding>
            <element signature="imports" expanded="true" />
            <element signature="e#1644#1645#0" expanded="true" />
            <element signature="e#1685#1686#0" expanded="true" />
            <element signature="e#1741#1742#0" expanded="true" />
            <element signature="e#1780#1781#0" expanded="true" />
          </folding>
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/src/com/github/lassana/wmparser/UniversityInfo.java">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.5369595">
          <caret line="133" column="16" selection-start-line="133" selection-start-column="16" selection-end-line="133" selection-end-column="16" />
          <folding>
            <element signature="imports" expanded="true" />
            <element signature="e#3473#3474#0" expanded="true" />
            <element signature="e#3506#3507#0" expanded="true" />
            <element signature="e#3571#3572#0" expanded="true" />
            <element signature="e#3615#3616#0" expanded="true" />
          </folding>
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/src/com/github/lassana/wmparser/ExcelOutputter.java">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.6443515">
          <caret line="140" column="46" selection-start-line="140" selection-start-column="46" selection-end-line="140" selection-end-column="46" />
          <folding>
            <element signature="imports" expanded="true" />
            <element signature="e#1665#1666#0" expanded="true" />
            <element signature="e#1713#1714#0" expanded="true" />
          </folding>
        </state>
      </provider>
    </entry>
    <entry file="file://$PROJECT_DIR$/src/com/github/lassana/wmparser/Main.java">
      <provider selected="true" editor-type-id="text-editor">
        <state vertical-scroll-proportion="0.27196652">
          <caret line="13" column="14" selection-start-line="13" selection-start-column="14" selection-end-line="13" selection-end-column="14" />
          <folding>
            <element signature="imports" expanded="true" />
          </folding>
        </state>
      </provider>
    </entry>
  </component>
  <component name="masterDetails">
    <states>
      <state key="ArtifactsStructureConfigurable.UI">
        <settings>
          <artifact-editor />
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
      <state key="FacetStructureConfigurable.UI">
        <settings>
          <last-edited>No facets are configured</last-edited>
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
      <state key="GlobalLibrariesConfigurable.UI">
        <settings>
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
      <state key="JdkListConfigurable.UI">
        <settings>
          <last-edited>1.7</last-edited>
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
      <state key="ModuleStructureConfigurable.UI">
        <settings>
          <last-edited>webometrics-parser</last-edited>
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
                <option value="0.6" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
      <state key="ProjectLibrariesConfigurable.UI">
        <settings>
          <last-edited>commons-lang:commons-lang:2.6</last-edited>
          <splitter-proportions>
            <option name="proportions">
              <list>
                <option value="0.2" />
              </list>
            </option>
          </splitter-proportions>
        </settings>
      </state>
    </states>
  </component>
</project>


text:
from __future__ import unicode_literals

from six import BytesIO, StringIO

from openid import fetchers
from openid.yadis.constants import YADIS_ACCEPT_HEADER, YADIS_CONTENT_TYPE, YADIS_HEADER_NAME
from openid.yadis.parsehtml import MetaNotFound, findHTMLMeta

__all__ = ['discover', 'DiscoveryResult', 'DiscoveryFailure']

class DiscoveryFailure(Exception):
    """Raised when a YADIS protocol error occurs in the discovery process"""
    identity_url = None

    def __init__(self, message, http_response):
        Exception.__init__(self, message)
        self.http_response = http_response

class DiscoveryResult(object):
    """Contains the result of performing Yadis discovery on a URI"""

    # The URI that was passed to the fetcher
    request_uri = None

    # The result of following redirects from the request_uri
    normalized_uri = None

    # The URI from which the response text was returned (set to
    # None if there was no XRDS document found)
    xrds_uri = None

    # The content-type returned with the response_text
    content_type = None

    # The document returned from the xrds_uri
    response_text = None

    def __init__(self, request_uri):
        """Initialize the state of the object

        sets all attributes to None except the request_uri
        """
        self.request_uri = request_uri

    def usedYadisLocation(self):
        """Was the Yadis protocol's indirection used?"""
        if self.xrds_uri is None:
            return False
        return self.normalized_uri != self.xrds_uri

    def isXRDS(self):
        """Is the response text supposed to be an XRDS document?"""
        return (self.usedYadisLocation() or self.content_type == YADIS_CONTENT_TYPE)

def discover(uri):
    """Discover services for a given URI.

    @param uri: The identity URI as a well-formed http or https
        URI. The well-formedness and the protocol are not checked, but
        the results of this function are undefined if those properties
        do not hold.

    @return: DiscoveryResult object

    @raises Exception: Any exception that can be raised by fetching a URL with
        the given fetcher.
    @raises DiscoveryFailure: When the HTTP response does not have a 200 code.
    """
    result = DiscoveryResult(uri)
    resp = fetchers.fetch(uri, headers={'Accept': YADIS_ACCEPT_HEADER})
    if resp.status not in (200, 206):
        raise DiscoveryFailure(
            'HTTP Response status from identity URL host is not 200. '
            'Got status %r' % (resp.status,), resp)

    # Note the URL after following redirects
    result.normalized_uri = resp.final_url

    # Attempt to find out where to go to discover the document
    # or if we already have it
    result.content_type = resp.headers.get('content-type')

    result.xrds_uri = whereIsYadis(resp)

    if result.xrds_uri and result.usedYadisLocation():
        resp = fetchers.fetch(result.xrds_uri)
        if resp.status not in (200, 206):
            exc = DiscoveryFailure(
                'HTTP Response status from Yadis host is not 200. '
                'Got status %r' % (resp.status,), resp)
            exc.identity_url = result.normalized_uri
            raise exc
        result.content_type = resp.headers.get('content-type')

    result.response_text = resp.body
    return result

def whereIsYadis(resp):
    """Given a HTTPResponse, return the location of the Yadis document.

    May be the URL just retrieved, another URL, or None, if I can't
    find any.

    [non-blocking]

    @returns: six.text_type or None
    """
    # Attempt to find out where to go to discover the document
    # or if we already have it
    content_type = resp.headers.get('content-type')

    # According to the spec, the content-type header must be an exact
    # match, or else we have to look for an indirection.
    if content_type and content_type.split(';', 1)[0].lower() == YADIS_CONTENT_TYPE:
        return resp.final_url
    else:
        # Try the header
        yadis_loc = resp.headers.get(YADIS_HEADER_NAME.lower())

        if not yadis_loc:
            # Parse as HTML if the header is missing.
            #
            # XXX: do we want to do something with content-type, like
            # have a whitelist or a blacklist (for detecting that it's
            # HTML)?

            # Decode body by encoding of file
            content_type = content_type or ''
            encoding = content_type.rsplit(';', 1)
            if len(encoding) == 2 and encoding[1].strip().startswith('charset='):
                encoding = encoding[1].split('=', 1)[1].strip()
            else:
                encoding = 'UTF-8'

            try:
                buff = StringIO(resp.body.decode(encoding))
            except UnicodeError:
                # Keep encoded version in case yadis location can be found before encoding shut this up.
                # Possible errors will be caught lower.
                buff = BytesIO(resp.body)

            try:
                yadis_loc = findHTMLMeta(buff)
            except (MetaNotFound, UnicodeError):
                # UnicodeError: Response body could not be encoded and xrds location
                # could not be found before troubles occurs.
                pass

        return yadis_loc


text:
import Scene from './Scene';

function InstantSpectating(spec){

    let { pawnSprites, landSprites } = spec;

    return new Scene(spec, {
        name: 'INSTANT_SPECTATING',
        uiElements: { landSprites:true,
                      regionBorders:true,
                      pawnSprites:true,
                      messages:true,
                      optionButtons: true },
        bindSignals: {
            pawns: {
                onCreated,
                onDestroyed,
            },
            regions: {
                onHexesChangedOwner: landSprites.refreshHexes
            }
        }
    });

    function onCreated(pawn) {
        pawnSprites.getOrCreate(pawn.hex, pawn.pawnType);
    }
    function onDestroyed(pawn) {
        pawnSprites.destroySprite(pawn.hex);
    }
}

export default InstantSpectating;


text:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>WinPcap: Authentication methods supported by the RPCAP protocol</title>
<link href="style.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">

Main Page

Related Pages

Modules

Data Structures

Files

Authentication methods supported by the RPCAP protocol

[Exported Structures and Definitions]

Defines

#define 	RPCAP_RMTAUTH_NULL   0

 	It defines the NULL authentication.

#define 	RPCAP_RMTAUTH_PWD   1

 	It defines the username/password authentication.

Define Documentation

          #define RPCAP_RMTAUTH_NULL   0

It defines the NULL authentication.

This value has to be used within the 'type' member of the pcap_rmtauth structure. The 'NULL' authentication has to be equal to 'zero', so that old applications can just put every field of struct pcap_rmtauth to zero, and it does work.

Definition at line 304 of file remote-ext.h.

          #define RPCAP_RMTAUTH_PWD   1

It defines the username/password authentication.

With this type of authentication, the RPCAP protocol will use the username/ password provided to authenticate the user on the remote machine. If the authentication is successful (and the user has the right to open network devices) the RPCAP connection will continue; otherwise it will be dropped.

This value has to be used within the 'type' member of the pcap_rmtauth structure.

Definition at line 315 of file remote-ext.h.

documentation. Copyright (c) 2002-2005 Politecnico di Torino. Copyright (c) 2005-2009
CACE Technologies. All rights reserved.


text:
module Twilio
  module TwiML
    ##
    # <Response> TwiML for Voice
    class VoiceResponse < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Response'

        yield(self) if block_given?
      end

      ##
      # Create a new <Dial> element
      # number:: Phone number to dial
      # action:: Action URL
      # method:: Action URL method
      # timeout:: Time to wait for answer
      # hangup_on_star:: Hangup call on star press
      # time_limit:: Max time length
      # caller_id:: Caller ID to display
      # record:: Record the call
      # trim:: Trim the recording
      # recording_status_callback:: Recording status callback URL
      # recording_status_callback_method:: Recording status callback URL method
      # answer_on_bridge:: Preserve the ringing behavior of the inbound call until the Dialed call picks up
      # ring_tone:: Ringtone allows you to override the ringback tone that Twilio will play back to the caller while executing the Dial
      # keyword_args:: additional attributes
      def dial(number: nil, action: nil, method: nil, timeout: nil, hangup_on_star: nil, time_limit: nil, caller_id: nil, record: nil, trim: nil, recording_status_callback: nil, recording_status_callback_method: nil, answer_on_bridge: nil, ring_tone: nil, **keyword_args)
        dial = Dial.new(number: number, action: action, method: method, timeout: timeout, hangup_on_star: hangup_on_star, time_limit: time_limit, caller_id: caller_id, record: record, trim: trim, recording_status_callback: recording_status_callback, recording_status_callback_method: recording_status_callback_method, answer_on_bridge: answer_on_bridge, ring_tone: ring_tone, **keyword_args)

        yield(dial) if block_given?
        append(dial)
      end

      ##
      # Create a new <Echo> element
      # keyword_args:: additional attributes
      def echo(**keyword_args)
        append(Echo.new(**keyword_args))
      end

      ##
      # Create a new <Enqueue> element
      # name:: Friendly name
      # action:: Action URL
      # method:: Action URL method
      # wait_url:: Wait URL
      # wait_url_method:: Wait URL method
      # workflow_sid:: TaskRouter Workflow SID
      # keyword_args:: additional attributes
      def enqueue(name: nil, action: nil, method: nil, wait_url: nil, wait_url_method: nil, workflow_sid: nil, **keyword_args)
        enqueue = Enqueue.new(name: name, action: action, method: method, wait_url: wait_url, wait_url_method: wait_url_method, workflow_sid: workflow_sid, **keyword_args)

        yield(enqueue) if block_given?
        append(enqueue)
      end

      ##
      # Create a new <Gather> element
      # input:: Input type Twilio should accept
      # action:: Action URL
      # method:: Action URL method
      # timeout:: Time to wait to gather input
      # speech_timeout:: Time to wait to gather speech input and it should be either auto or a positive integer.
      # max_speech_time:: Max allowed time for speech input
      # profanity_filter:: Profanity Filter on speech
      # finish_on_key:: Finish gather on key
      # num_digits:: Number of digits to collect
      # partial_result_callback:: Partial result callback URL
      # partial_result_callback_method:: Partial result callback URL method
      # language:: Language to use
      # hints:: Speech recognition hints
      # barge_in:: Stop playing media upon speech
      # keyword_args:: additional attributes
      def gather(input: nil, action: nil, method: nil, timeout: nil, speech_timeout: nil, max_speech_time: nil, profanity_filter: nil, finish_on_key: nil, num_digits: nil, partial_result_callback: nil, partial_result_callback_method: nil, language: nil, hints: nil, barge_in: nil, **keyword_args)
        gather = Gather.new(input: input, action: action, method: method, timeout: timeout, speech_timeout: speech_timeout, max_speech_time: max_speech_time, profanity_filter: profanity_filter, finish_on_key: finish_on_key, num_digits: num_digits, partial_result_callback: partial_result_callback, partial_result_callback_method: partial_result_callback_method, language: language, hints: hints, barge_in: barge_in, **keyword_args)

        yield(gather) if block_given?
        append(gather)
      end

      ##
      # Create a new <Hangup> element
      # keyword_args:: additional attributes
      def hangup(**keyword_args)
        append(Hangup.new(**keyword_args))
      end

      ##
      # Create a new <Leave> element
      # keyword_args:: additional attributes
      def leave(**keyword_args)
        append(Leave.new(**keyword_args))
      end

      ##
      # Create a new <Pause> element
      # length:: Length in seconds to pause
      # keyword_args:: additional attributes
      def pause(length: nil, **keyword_args)
        append(Pause.new(length: length, **keyword_args))
      end

      ##
      # Create a new <Play> element
      # url:: Media URL
      # loop:: Times to loop media
      # digits:: Play DTMF tones for digits
      # keyword_args:: additional attributes
      def play(url: nil, loop: nil, digits: nil, **keyword_args)
        append(Play.new(url: url, loop: loop, digits: digits, **keyword_args))
      end

      ##
      # Create a new <Queue> element
      # name:: Queue name
      # url:: Action URL
      # method:: Action URL method
      # reservation_sid:: TaskRouter Reservation SID
      # post_work_activity_sid:: TaskRouter Activity SID
      # keyword_args:: additional attributes
      def queue(name, url: nil, method: nil, reservation_sid: nil, post_work_activity_sid: nil, **keyword_args)
        append(Queue.new(name, url: url, method: method, reservation_sid: reservation_sid, post_work_activity_sid: post_work_activity_sid, **keyword_args))
      end

      ##
      # Create a new <Record> element
      # action:: Action URL
      # method:: Action URL method
      # timeout:: Timeout to begin recording
      # finish_on_key:: Finish recording on key
      # max_length:: Max time to record in seconds
      # play_beep:: Play beep
      # trim:: Trim the recording
      # recording_status_callback:: Status callback URL
      # recording_status_callback_method:: Status callback URL method
      # transcribe:: Transcribe the recording
      # transcribe_callback:: Transcribe callback URL
      # keyword_args:: additional attributes
      def record(action: nil, method: nil, timeout: nil, finish_on_key: nil, max_length: nil, play_beep: nil, trim: nil, recording_status_callback: nil, recording_status_callback_method: nil, transcribe: nil, transcribe_callback: nil, **keyword_args)
        append(Record.new(action: action, method: method, timeout: timeout, finish_on_key: finish_on_key, max_length: max_length, play_beep: play_beep, trim: trim, recording_status_callback: recording_status_callback, recording_status_callback_method: recording_status_callback_method, transcribe: transcribe, transcribe_callback: transcribe_callback, **keyword_args))
      end

      ##
      # Create a new <Redirect> element
      # url:: Redirect URL
      # method:: Redirect URL method
      # keyword_args:: additional attributes
      def redirect(url, method: nil, **keyword_args)
        append(Redirect.new(url, method: method, **keyword_args))
      end

      ##
      # Create a new <Reject> element
      # reason:: Rejection reason
      # keyword_args:: additional attributes
      def reject(reason: nil, **keyword_args)
        append(Reject.new(reason: reason, **keyword_args))
      end

      ##
      # Create a new <Say> element
      # message:: Message to say
      # voice:: Voice to use
      # loop:: Times to loop message
      # language:: Message langauge
      # keyword_args:: additional attributes
      def say(message, voice: nil, loop: nil, language: nil, **keyword_args)
        append(Say.new(message, voice: voice, loop: loop, language: language, **keyword_args))
      end

      ##
      # Create a new <Sms> element
      # message:: Message body
      # to:: Number to send message to
      # from:: Number to send message from
      # action:: Action URL
      # method:: Action URL method
      # status_callback:: Status callback URL
      # keyword_args:: additional attributes
      def sms(message, to: nil, from: nil, action: nil, method: nil, status_callback: nil, **keyword_args)
        append(Sms.new(message, to: to, from: from, action: action, method: method, status_callback: status_callback, **keyword_args))
      end
    end

    ##
    # <Sms> TwiML Noun
    class Sms < TwiML
      def initialize(message, **keyword_args)
        super(**keyword_args)
        @name = 'Sms'
        @value = message
        yield(self) if block_given?
      end
    end

    ##
    # <Say> TwiML Verb
    class Say < TwiML
      def initialize(message, **keyword_args)
        super(**keyword_args)
        @name = 'Say'
        @value = message
        yield(self) if block_given?
      end
    end

    ##
    # <Reject> TwiML Verb
    class Reject < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Reject'

        yield(self) if block_given?
      end
    end

    ##
    # <Redirect> TwiML Verb
    class Redirect < TwiML
      def initialize(url, **keyword_args)
        super(**keyword_args)
        @name = 'Redirect'
        @value = url
        yield(self) if block_given?
      end
    end

    ##
    # <Record> TwiML Verb
    class Record < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Record'

        yield(self) if block_given?
      end
    end

    ##
    # <Queue> TwiML Noun
    class Queue < TwiML
      def initialize(name, **keyword_args)
        super(**keyword_args)
        @name = 'Queue'
        @value = name
        yield(self) if block_given?
      end
    end

    ##
    # <Play> TwiML Verb
    class Play < TwiML
      def initialize(url: nil, **keyword_args)
        super(**keyword_args)
        @name = 'Play'
        @value = url unless url.nil?
        yield(self) if block_given?
      end
    end

    ##
    # <Pause> TwiML Verb
    class Pause < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Pause'

        yield(self) if block_given?
      end
    end

    ##
    # <Leave> TwiML Verb
    class Leave < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Leave'

        yield(self) if block_given?
      end
    end

    ##
    # <Hangup> TwiML Verb
    class Hangup < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Hangup'

        yield(self) if block_given?
      end
    end

    ##
    # <Gather> TwiML Verb
    class Gather < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Gather'

        yield(self) if block_given?
      end

      ##
      # Create a new <Say> element
      # message:: Message to say
      # voice:: Voice to use
      # loop:: Times to loop message
      # language:: Message langauge
      # keyword_args:: additional attributes
      def say(message, voice: nil, loop: nil, language: nil, **keyword_args)
        append(Say.new(message, voice: voice, loop: loop, language: language, **keyword_args))
      end

      ##
      # Create a new <Pause> element
      # length:: Length in seconds to pause
      # keyword_args:: additional attributes
      def pause(length: nil, **keyword_args)
        append(Pause.new(length: length, **keyword_args))
      end

      ##
      # Create a new <Play> element
      # url:: Media URL
      # loop:: Times to loop media
      # digits:: Play DTMF tones for digits
      # keyword_args:: additional attributes
      def play(url: nil, loop: nil, digits: nil, **keyword_args)
        append(Play.new(url: url, loop: loop, digits: digits, **keyword_args))
      end
    end

    ##
    # <Enqueue> TwiML Noun
    class Enqueue < TwiML
      def initialize(name: nil, **keyword_args)
        super(**keyword_args)
        @name = 'Enqueue'
        @value = name unless name.nil?
        yield(self) if block_given?
      end

      ##
      # Create a new <Task> element
      # body:: TaskRouter task attributes
      # keyword_args:: additional attributes
      def task(body, **keyword_args)
        append(Task.new(body, **keyword_args))
      end
    end

    ##
    # <Task> TwiML Noun
    class Task < TwiML
      def initialize(body, **keyword_args)
        super(**keyword_args)
        @name = 'Task'
        @value = body
        yield(self) if block_given?
      end
    end

    ##
    # <Echo> TwiML Verb
    class Echo < TwiML
      def initialize(**keyword_args)
        super(**keyword_args)
        @name = 'Echo'

        yield(self) if block_given?
      end
    end

    ##
    # <Dial> TwiML Verb
    class Dial < TwiML
      def initialize(number: nil, **keyword_args)
        super(**keyword_args)
        @name = 'Dial'
        @value = number unless number.nil?
        yield(self) if block_given?
      end

      ##
      # Create a new <Client> element
      # name:: Client name
      # url:: Client URL
      # method:: Client URL Method
      # status_callback_event:: Events to trigger status callback
      # status_callback:: Status Callback URL
      # status_callback_method:: Status Callback URL Method
      # keyword_args:: additional attributes
      def client(name, url: nil, method: nil, status_callback_event: nil, status_callback: nil, status_callback_method: nil, **keyword_args)
        append(Client.new(name, url: url, method: method, status_callback_event: status_callback_event, status_callback: status_callback, status_callback_method: status_callback_method, **keyword_args))
      end

      ##
      # Create a new <Conference> element
      # name:: Conference name
      # muted:: Join the conference muted
      # beep:: Play beep when joining
      # start_conference_on_enter:: Start the conference on enter
      # end_conference_on_exit:: End the conferenceon exit
      # wait_url:: Wait URL
      # wait_method:: Wait URL method
      # max_participants:: Maximum number of participants
      # record:: Record the conference
      # region:: Conference region
      # whisper:: Call whisper
      # trim:: Trim the conference recording
      # status_callback_event:: Events to call status callback URL
      # status_callback:: Status callback URL
      # status_callback_method:: Status callback URL method
      # recording_status_callback:: Recording status callback URL
      # recording_status_callback_method:: Recording status callback URL method
      # event_callback_url:: Event callback URL
      # keyword_args:: additional attributes
      def conference(name, muted: nil, beep: nil, start_conference_on_enter: nil, end_conference_on_exit: nil, wait_url: nil, wait_method: nil, max_participants: nil, record: nil, region: nil, whisper: nil, trim: nil, status_callback_event: nil, status_callback: nil, status_callback_method: nil, recording_status_callback: nil, recording_status_callback_method: nil, event_callback_url: nil, **keyword_args)
        append(Conference.new(name, muted: muted, beep: beep, start_conference_on_enter: start_conference_on_enter, end_conference_on_exit: end_conference_on_exit, wait_url: wait_url, wait_method: wait_method, max_participants: max_participants, record: record, region: region, whisper: whisper, trim: trim, status_callback_event: status_callback_event, status_callback: status_callback, status_callback_method: status_callback_method, recording_status_callback: recording_status_callback, recording_status_callback_method: recording_status_callback_method, event_callback_url: event_callback_url, **keyword_args))
      end

      ##
      # Create a new <Number> element
      # phone_number:: Phone Number to dial
      # send_digits:: DTMF tones to play when the call is answered
      # url:: TwiML URL
      # method:: TwiML URL method
      # status_callback_event:: Events to call status callback
      # status_callback:: Status callback URL
      # status_callback_method:: Status callback URL method
      # keyword_args:: additional attributes
      def number(phone_number, send_digits: nil, url: nil, method: nil, status_callback_event: nil, status_callback: nil, status_callback_method: nil, **keyword_args)
        append(Number.new(phone_number, send_digits: send_digits, url: url, method: method, status_callback_event: status_callback_event, status_callback: status_callback, status_callback_method: status_callback_method, **keyword_args))
      end

      ##
      # Create a new <Queue> element
      # name:: Queue name
      # url:: Action URL
      # method:: Action URL method
      # reservation_sid:: TaskRouter Reservation SID
      # post_work_activity_sid:: TaskRouter Activity SID
      # keyword_args:: additional attributes
      def queue(name, url: nil, method: nil, reservation_sid: nil, post_work_activity_sid: nil, **keyword_args)
        append(Queue.new(name, url: url, method: method, reservation_sid: reservation_sid, post_work_activity_sid: post_work_activity_sid, **keyword_args))
      end

      ##
      # Create a new <Sim> element
      # sim_sid:: SIM SID
      # keyword_args:: additional attributes
      def sim(sim_sid, **keyword_args)
        append(Sim.new(sim_sid, **keyword_args))
      end

      ##
      # Create a new <Sip> element
      # sip_url:: SIP URL
      # username:: SIP Username
      # password:: SIP Password
      # url:: Action URL
      # method:: Action URL method
      # status_callback_event:: Status callback events
      # status_callback:: Status callback URL
      # status_callback_method:: Status callback URL method
      # keyword_args:: additional attributes
      def sip(sip_url, username: nil, password: nil, url: nil, method: nil, status_callback_event: nil, status_callback: nil, status_callback_method: nil, **keyword_args)
        append(Sip.new(sip_url, username: username, password: password, url: url, method: method, status_callback_event: status_callback_event, status_callback: status_callback, status_callback_method: status_callback_method, **keyword_args))
      end
    end

    ##
    # <Sip> TwiML Noun
    class Sip < TwiML
      def initialize(sip_url, **keyword_args)
        super(**keyword_args)
        @name = 'Sip'
        @value = sip_url
        yield(self) if block_given?
      end
    end

    ##
    # <Sim> TwiML Noun
    class Sim < TwiML
      def initialize(sim_sid, **keyword_args)
        super(**keyword_args)
        @name = 'Sim'
        @value = sim_sid
        yield(self) if block_given?
      end
    end

    ##
    # <Number> TwiML Noun
    class Number < TwiML
      def initialize(phone_number, **keyword_args)
        super(**keyword_args)
        @name = 'Number'
        @value = phone_number
        yield(self) if block_given?
      end
    end

    ##
    # <Conference> TwiML Noun
    class Conference < TwiML
      def initialize(name, **keyword_args)
        super(**keyword_args)
        @name = 'Conference'
        @value = name
        yield(self) if block_given?
      end
    end

    ##
    # <Client> TwiML Noun
    class Client < TwiML
      def initialize(name, **keyword_args)
        super(**keyword_args)
        @name = 'Client'
        @value = name
        yield(self) if block_given?
      end
    end
  end
end


text:
{% extends "board_base.html" %}
{% load i18n %}

{% block sub_title %}{% trans "Password reset" %}{% endblock sub_title %}

{% block breadcrumb %}{% endblock breadcrumb %}

{% block content %}

{% trans "Password reset" %}

{% trans "We've emailed you instructions for setting your password, if an account exists with the email you entered. You should receive them shortly." %}

{% trans "If you don't receive an email, please make sure you've entered the address you registered with, and check your spam folder." %}

{% endblock content %}