Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
 

Related Documentation

 

import

Syntax

import href;

Release Information

Statement introduced in version 1.0 of the SLAX language.

Description

Import rules from an external file or style sheet, which provide access to all the declarations and templates within the imported item. Any import statements must be the first elements in the script or style sheet. The path can be any URI. The path ../import/junos.xsl is standard for all commit scripts, op scripts, and event scripts.

Imported rules are overwritten by any subsequent matching rules within the importing script. If more than one file or style sheet is imported, the items imported last override each previous import where the rules match.

Attributes

href

Specifies the location of the imported file or style sheet.

SLAX Example

In the example, the main script imports the file route-rules.slax, which contains a template rule for <route> elements.

version 1.1;
import "route-rules.slax";

match route {
    <routes> {
        apply-imports;
    }
}
 

Related Documentation

 

Published: 2013-03-05

 

Related Documentation

 

Published: 2013-03-05