Data::Edit::Xml::SDL - Create SDL file map from a set of linted xml files produced by Data::Edit::Xml::Lint
Create an SDL file map from a set of linted xml files produced by Data::Edit::Xml::Lint
my $s = Data::Edit::Xml::SDL::new(); $s->sourcebasepath = 'C:\frame\batch1\out'; $s->targetFolder = qq(RyffineImportSGIfm); $s->imagePath = qq(images); $s->version = 1; say STDERR $s->createSDLFileMap(qw(. xml));
Produces:
<?xml version="1.0" encoding="utf-8"?> <filemap sourcebasepath="C:\hp\frame\batch1\out" version="12.0.0.0">; <file fileextension=".ditamap" > <ishobject ishref="GUID-D7147C7F-2017-0012-FRMB-000000000002" ishtype="ISHMasterDoc"> <ishfields> <ishfield level="logical" name="FTITLE" xml:space="preserve">bm_0003388-002</ishfield>' <ishfield level="version" name="VERSION" xml:space="preserve">1</ishfield> <ishfield level="lng" name="DOC-LANGUAGE" xml:space="preserve">en-US</ishfield> <ishfield name="FAUTHOR" level="lng" xml:space="preserve">bill.gearhart@hpe.com</ishfield> </ishfields> </ishobject> </file>
etc.
Construct a new SDL file map creator
Create a new SDL file map creator - call this method statically as in Data::Edit::Xml::Lint::new()
Attributes describing a lint
Prefix this folder (if supplied) to the filepath
The fileType of the file to be processed
folderHasMixedContent field
IshType field
Image path relative to sourcebasepath
The language of the content, defaults to: 'en-US'
The lint of the file to be processed
Version of SDL we are using, defaults to: '12.0.0.0'
Sub folder for file on SDL: maps, topics
Path to source to be uploaded
The SDL target folder to be used
Version of the input content
Generate an SDL file map
Generate an SDL file map for a selected set of files
1 $sdl Sdl 2 @foldersAndExtensions Directory tree search specification
Line one of all xml files
File map tag
File tag
1 $sdl Sdl file map creator 2 $images Processing an image file or not
IshObject tag
FTITLE tag
Version tag
DOC-LANGUAGE tag
Author tag
Resolution
createSDLFileMap
filePathFolder
fileType
folderHasMixedContent
getAuthor
getDocLanguage
getFile
getFileMap
getFTitle
getIshObject
getResolution
getVersion
imagePath
ishType
language
lint
new
sdlVersion
section
sourcebasepath
targetFolder
version
xmlLineOne
This module is written in 100% Pure Perl and, thus, it is easy to read, use, modify and install.
Standard Module::Build process for building and installing modules:
perl Build.PL ./Build ./Build test ./Build install
philiprbrenan@gmail.com
http://www.appaapps.com
Copyright (c) 2016-2017 Philip R Brenan.
This module is free software. It may be used, redistributed and/or modified under the same terms as Perl itself.
To install Data::Edit::Xml::SDL, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Data::Edit::Xml::SDL
CPAN shell
perl -MCPAN -e shell install Data::Edit::Xml::SDL
For more information on module installation, please visit the detailed CPAN module installation guide.