Skip to content

Commit

Permalink
MDL-29515 drop 1.9 xmldb classes and methods (deprecated since 2.0)
Browse files Browse the repository at this point in the history
  • Loading branch information
skodak committed Mar 17, 2012
1 parent de640a2 commit e763c27
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 110 deletions.
22 changes: 0 additions & 22 deletions lib/xmldb/xmldb_field.php
Expand Up @@ -60,17 +60,6 @@ function __construct($name, $type=null, $precision=null, $unsigned=null, $notnul
$this->set_attributes($type, $precision, $unsigned, $notnull, $sequence, $default, $previous);
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here

function setAttributes($type, $precision=null, $unsigned=null, $notnull=null, $sequence=null, $enum=null, $enumvalues=null, $default=null, $previous=null) {

debugging('XMLDBField->setAttributes() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_field->set_attributes() instead.', DEBUG_DEVELOPER);

return $this->set_attributes($type, $precision, $unsigned, $notnull, $sequence, $default, $previous);
}
/// Deprecated API ends here

/**
* Set all the attributes of one xmldb_field
*
Expand Down Expand Up @@ -748,14 +737,3 @@ function validateDefinition(xmldb_table $xmldb_table=null) {
return null;
}
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
class XMLDBField extends xmldb_field {

function __construct($name) {
parent::__construct($name);
}

}
/// Deprecated API ends here
21 changes: 0 additions & 21 deletions lib/xmldb/xmldb_index.php
Expand Up @@ -57,16 +57,6 @@ function __construct($name, $type=null, $fields=array()) {
return $this->set_attributes($type, $fields);
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
function setAttributes($type, $fields) {

debugging('XMLDBIndex->setAttributes() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_index->set_attributes() instead.', DEBUG_DEVELOPER);

return $this->set_attributes($type, $fields);
}
/// Deprecated API ends here

/**
* Set all the attributes of one xmldb_index
*
Expand Down Expand Up @@ -356,14 +346,3 @@ function validateDefinition(xmldb_table $xmldb_table=null) {
}

}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
class XMLDBIndex extends xmldb_index {

function __construct($name) {
parent::__construct($name);
}

}
/// Deprecated API ends here
22 changes: 0 additions & 22 deletions lib/xmldb/xmldb_key.php
Expand Up @@ -45,17 +45,6 @@ function __construct($name, $type=null, $fields=array(), $reftable=null, $reffie
$this->set_attributes($type, $fields, $reftable, $reffields);
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here

function setAttributes($type, $fields, $reftable=null, $reffields=null) {

debugging('XMLDBKey->setAttributes() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_key->set_attributes() instead.', DEBUG_DEVELOPER);

return $this->set_attributes($type, $fields, $reftable, $reffields);
}
/// Deprecated API ends here

/**
* Set all the attributes of one xmldb_key
*
Expand Down Expand Up @@ -469,14 +458,3 @@ function readableInfo() {
return $o;
}
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
class XMLDBKey extends xmldb_key {

function __construct($name) {
parent::__construct($name);
}

}
/// Deprecated API ends here
45 changes: 0 additions & 45 deletions lib/xmldb/xmldb_table.php
Expand Up @@ -704,17 +704,6 @@ function xmlOutput() {
return $o;
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
function addFieldInfo($name, $type, $precision=null, $unsigned=null, $notnull=null, $sequence=null, $enum=null, $enumvalues=null, $default=null, $previous=null) {

debugging('XMLDBTable->addFieldInfo() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_table->add_field() instead', DEBUG_DEVELOPER);

return $this->add_field($name, $type, $precision, $unsigned, $notnull, $sequence, $default, $previous);

}
/// Deprecated API ends here

/**
* This function will add one new field to the table with all
* its attributes defined
Expand All @@ -735,18 +724,6 @@ function add_field($name, $type, $precision=null, $unsigned=null, $notnull=null,
return $field;
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here

function addKeyInfo($name, $type, $fields, $reftable=null, $reffields=null) {

debugging('XMLDBTable->addKeyInfo() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_table->add_key() instead', DEBUG_DEVELOPER);

return $this->add_key($name, $type, $fields, $reftable, $reffields);

}
/// Deprecated API ends here

/**
* This function will add one new key to the table with all
* its attributes defined
Expand All @@ -762,17 +739,6 @@ function add_key($name, $type, $fields, $reftable=null, $reffields=null) {
$this->addKey($key);
}

/// TODO: Delete for 2.1 (deprecated in 2.0).
/// Deprecated API starts here
function addIndexInfo($name, $type, $fields) {

debugging('XMLDBTable->addIndexInfo() has been deprecated in Moodle 2.0. Will be out in Moodle 2.1. Please use xmldb_table->add_index() instead', DEBUG_DEVELOPER);

return $this->add_index($name, $type, $fields);

}
/// Deprecated API ends here

/**
* This function will add one new index to the table with all
* its attributes defined
Expand Down Expand Up @@ -830,14 +796,3 @@ function getAllErrors() {
}
}
}

/// TODO: Delete for 2.1 (deeprecated in 2.0).
/// Deprecated API starts here
class XMLDBTable extends xmldb_table {

function __construct($name) {
parent::__construct($name);
}

}
/// Deprecated API ends here

0 comments on commit e763c27

Please sign in to comment.