You are here

w3c_validator.install in W3C Validator 7

Same filename and directory in other branches
  1. 8 w3c_validator.install
  2. 6 w3c_validator.install

File

w3c_validator.install
View source
<?php

/**
 * Implements hook_schema().
 */
function w3c_validator_schema() {
  $schema['w3c_validator'] = array(
    'description' => 'Store already validated URI',
    'fields' => array(
      'wid' => array(
        'type' => 'serial',
        'not null' => TRUE,
        'description' => 'Primary Key: Unique link ID.',
      ),
      'uri' => array(
        'type' => 'text',
        'not null' => TRUE,
        'description' => 'The full qualified link.',
      ),
      'error_count' => array(
        'description' => t('Number of errors found during validation.'),
        'type' => 'int',
        'unsigned' => TRUE,
        'size' => 'small',
        'not null' => TRUE,
        'default' => 0,
        'disp-width' => '5',
      ),
      'errors' => array(
        'description' => t('Detailed information about validation errors.'),
        'type' => 'text',
        'size' => 'big',
      ),
      'warning_count' => array(
        'description' => t('Number of warnings found during validation.'),
        'type' => 'int',
        'unsigned' => TRUE,
        'size' => 'small',
        'not null' => TRUE,
        'default' => 0,
        'disp-width' => '5',
      ),
      'warnings' => array(
        'description' => t('Detailed information about warning errors.'),
        'type' => 'text',
        'size' => 'big',
      ),
      'validity' => array(
        'description' => t('A flag : TRUE if the validation is valid.'),
        'type' => 'int',
        'default' => 0,
        'not null' => TRUE,
      ),
      'need_validation' => array(
        'description' => t('A flag : TRUE is re-validation is needed.'),
        'type' => 'int',
        'default' => 1,
        'not null' => TRUE,
      ),
      'doctype' => array(
        'description' => t('Doctype of this page.'),
        'type' => 'varchar',
        'length' => '255',
        'not null' => TRUE,
        'default' => 'unknown',
      ),
      'charset' => array(
        'description' => t('Charset of this page.'),
        'type' => 'varchar',
        'length' => '255',
        'not null' => TRUE,
        'default' => 'unknown',
      ),
    ),
    'primary key' => array(
      'wid',
    ),
  );
  return $schema;
}

Functions

Namesort descending Description
w3c_validator_schema Implements hook_schema().