mn8 Language Reference | Index    

Style

SUMMARY: NO ATTRIBUTES  NO ELEMENTS  NO CONSTRUCTORS  NO OPERATORS  METHODS SUMMARYDETAIL: NO ATTRIBUTES  NO ELEMENTS  NO CONSTRUCTORS  NO OPERATORS  METHOD DETAILS

Description

Apply the given style over the xml document.

Usage

This is how simple is to apply a style (XSLT document) over an concept or string. Just load or produce the style and content and invoke Style.applyStyle on them.

            $xml = File.create("article.xml")
            $style = File.create("article.xsl")
            print Style.applyStyle($xml/content, $style/content)

Version: 0.1
Authors:Remus Pereni (http://neuro.nolimits.ro)
Location:
Inherits: Concept

Method List

static StringapplyStyle (String $to, String $style)
top
Methods inherited from: Concept
cloneConcept, extendsConcept, fromXML, getAllInheritedConcepts, getConceptAttribute, getConceptAttributeField, getConceptAttributeFields, getConceptAttributes, getConceptConstructors, getConceptElement, getConceptElementField, getConceptElementFields, getConceptElements, getConceptLabel, getConceptMethod, getConceptMethods, getConceptOperators, getConceptType, getErrorHandler, getInheritedConcepts, getResourceURI, hasConceptAttribute, hasConceptElement, hasConceptMethod, hasPath, isHidden, loadContent, setConceptLabel, setErrorHandler, setHidden, setShowEmpty, showEmpty, toTXT, toXML, setResourceURI

Detailed Method Info

static applyStyle (String $to, String $style)
Parameters:
$to :The string to apply the style.
$style :The style to apply.
Returns: String
Exceptions:
transformerConfigException :
(Error)
If unable to apply style on specified document.
transformerException :
(Error)
If unable to apply style on specified document.

Applies the given $style to the specified xml and returns the result.

            $xml = File.create("article.xml")
            $style = File.create("article.xsl")
            print Style.applyStyle($xml/content, $style/content)
            

top