Input/Output
Interfacing with other software
Collaboration diagram for Input/Output:

## Modules

| ASL Binary Dump (ABD) format

## Classes

class | asl::WriterVTKXML

## Functions

SPDataWithGhostNodesACLData | asl::read (const string &fileName, unsigned int arrayNum, acl::CommandQueue queue=acl::hardware.defaultQueue)
SPDataWithGhostNodesACLData | asl::readSurface (const string &fileName, double dx, acl::CommandQueue queue=acl::hardware.defaultQueue)
void | asl::writeMAT (const string &fileName, const AbstractData &data, const string &name)
| writes `data` in a MatLab file More...
void | asl::writeMAT (const string &fileName, vector< pair< SPAbstractData, string >> data)
| writes `data` in a MatLab file More...
void | asl::writeMAT (const string &fileName, vector< pair< acl::Element, string >> data)
| writes `data` in a MatLab file More...
void | asl::writeMAT (const string &fileName, Probe &probe, unsigned int component, const string &name)
| writes `probe` values in a MatLab file More...
void | asl::writeVTKXML (const std::string &fileName, const AbstractData &data, const std::string &name)

## Detailed Description

## Function Documentation

## read()

SPDataWithGhostNodesACLData asl::read | ( | const string & | fileName,
|  | unsigned int | arrayNum,
|  | acl::CommandQueue | queue = `acl::hardware.defaultQueue`
| ) |  |

Reads `arrayNum` of data from a file (detecting its format through its extension) to asl data and puts it in `queue`; returns asl data; Supported formats: .vtk .vti .mnc .dcm

Examples
  poroelastic.cc, and testVTK_IO.cc.

## readSurface()

SPDataWithGhostNodesACLData asl::readSurface | ( | const string & | fileName,
|  | double | dx,
|  | acl::CommandQueue | queue = `acl::hardware.defaultQueue`
| ) |  |

Reads `arrayNum` of data from a file (detecting its format through its extension) to asl data and puts it in `queue`; returns asl data; Supported formats: .vtp .stl

Examples
  bus_wind.cc, compressor.cc, locomotive.cc, locomotive_laminar.cc, locomotive_stability.cc, and testVTK_IO.cc.

## writeMAT() [1/4]

void asl::writeMAT | ( | const string & | fileName,
|  | const AbstractData & | data,
|  | const string & | name
| ) |  |

writes `data` in a MatLab file

## writeMAT() [2/4]

void asl::writeMAT | ( | const string & | fileName,
|  | Probe & | probe,
|  | unsigned int | component,
|  | const string & | name
| ) |  |

writes `probe` values in a MatLab file

## writeMAT() [3/4]

void asl::writeMAT | ( | const string & | fileName,
|  | vector< pair< acl::Element, string >> | data
| ) |  |

writes `data` in a MatLab file

Parameters

  fileName | name of the file;
  data | is vector which contains pairs of the corresponding data and its name

## writeMAT() [4/4]

void asl::writeMAT | ( | const string & | fileName,
|  | vector< pair< SPAbstractData, string >> | data
| ) |  |

writes `data` in a MatLab file

Parameters

  fileName | name of the file;
  data | is vector which contains pairs of the corresponding data and its name

## writeVTKXML()

void asl::writeVTKXML | ( | const std::string & | fileName,
|  | const AbstractData & | data,
|  | const std::string & | name
| ) |  |

writes `data` in a file with VTK XML format "vti"

Examples
  testDistanceFunction.cc, and testVTK_IO.cc.