mediawiki-extensions-Visual.../modules/ve2/dm/nodes/ve.dm.TableRowNode.js
Trevor Parscal 86591e5325 Restructured static node rules
Change-Id: I7023e1f334694d59767491f1010e7c4c59c0ce54
2012-05-21 17:39:12 -07:00

39 lines
804 B
JavaScript

/**
* DataModel node for a table row.
*
* @class
* @constructor
* @extends {ve.dm.BranchNode}
* @param {ve.dm.BranchNode[]} [children] Child nodes to attach
* @param {Object} [attributes] Reference to map of attribute key/value pairs
*/
ve.dm.TableRowNode = function( children, attributes ) {
// Inheritance
ve.dm.BranchNode.call( this, 'tableRow', children, attributes );
};
/* Static Members */
/**
* Node rules.
*
* @see ve.dm.NodeFactory
* @static
* @member
*/
ve.dm.TableRowNode.rules = {
'isWrapped': true,
'isContent': false,
'canContainContent': false,
'childNodeTypes': ['tableCell'],
'parentNodeTypes': ['table']
};
/* Registration */
ve.dm.factory.register( 'tableRow', ve.dm.TableRowNode );
/* Inheritance */
ve.extendClass( ve.dm.TableRowNode, ve.dm.BranchNode );