Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM-10943: References to TranForward and TranInverse are confusing #22

Merged
merged 2 commits into from
Jun 19, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 2 additions & 4 deletions include/astshim/Frame.h
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,7 @@ class Frame : public Mapping {
system found is used. However, the overall Mapping between
the source and destination coordinate systems is also
examined. Preference is given to cases where both the
forward and inverse transformations are defined (as indicated
by the TranForward and TranInverse attributes). If only one
forward and inverse transformations are defined. If only one
transformation is defined, the forward one is preferred.
- If the domain of the intermediate coordinate system matches
the current "domainlist" field, the conversion path is
Expand Down Expand Up @@ -558,8 +557,7 @@ class Frame : public Mapping {
Mapping between the target coordinate system and the
resulting Frame is also examined. Preference is given to
cases where both the forward and inverse transformations are
defined (as indicated by the TranForward and TranInverse
attributes). If only one transformation is defined, the
defined. If only one transformation is defined, the
forward one is preferred.
- If a match is found and the domain of the resulting Frame also
matches the current "domainlist" field, it is
Expand Down
4 changes: 2 additions & 2 deletions include/astshim/FrameSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -301,8 +301,8 @@ class FrameSet : public Frame {
between the two supplied @ref Frame "Frames", including the specified end frames.
- It should always be possible to generate the @ref Mapping requested, but this does not
necessarily guarantee that it will be able to perform the required coordinate conversion.
If necessary, the `TranForward` and `TranInverse` attributes of the returned @ref Mapping
should be inspected to determine if the required transformation is available.
If necessary, call `hasForward` or `hasInverse` on the returned @ref Mapping
to determine if the required transformation is available.
*/
std::shared_ptr<Mapping> getMapping(int ind1 = BASE, int ind2 = CURRENT) const {
AstObject *rawMap = reinterpret_cast<AstObject *>(astGetMapping(getRawPtr(), ind1, ind2));
Expand Down
6 changes: 2 additions & 4 deletions include/astshim/LutMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,8 @@ In addition to those attributes provided by @ref Mapping and @ref Object,

### Notes

- If the entries in the lookup table either increase or decrease monotonically, then the `LutMap`'s
`TranInverse` attribute will have a value of one, indicating that the inverse transformation
can be performed. Otherwise, it will have a value of zero, so that any attempt to use
the inverse transformation will result in an error.
- If the entries in the lookup table increase or decrease monotonically, then the LutMap
will have an inverse transformation; otherwise it will not.
*/
class LutMap : public Mapping {
friend class Object;
Expand Down
6 changes: 2 additions & 4 deletions include/astshim/MatrixMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ class MatrixMap : public Mapping {
/**
Construct a MatrixMap from a 2-d matrix

@note The inverse transformation (`TranInverse` attribute) will only be available if `matrix`
is square and non-singular.
@note The inverse transformation will only be available if `matrix` is square and non-singular.

@param[in] matrix The transformation matrix, where:
- The number of input coordinates is the number of columns.
Expand All @@ -63,8 +62,7 @@ class MatrixMap : public Mapping {
/**
Construct a MatrixMap from a 1-d vector of diagonal elements of a diagonal matrix

@note The inverse transformation (`TranInverse` attribute) will always be available
when constructed from a diagonal matrix.
@note The inverse transformation will always be available when constructed from a diagonal matrix.

@param[in] diag The diagonal elements of a diagonal matrix as a vector;
the number of input and output coordinates is the length of the vector.
Expand Down
1 change: 1 addition & 0 deletions include/astshim/Stream.h
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ class FileStream : public Stream {

virtual ~FileStream() {}

/// Get the path to the file, as a string
std::string getPath() const { return _path; }

private:
Expand Down