Getting Started Documentation Glish Learn More Programming Contact Us
Version 1.9 Build 1488
News FAQ
Search Home


next up previous contents index
Next: coordsys.done - Function Up: coordsys - Tool Previous: coordsys.coordinatetype - Function


coordsys.copy - Function



Package general
Module images
Tool coordsys


Copy this Coordsys tool


Synopsis
copy()


Returns
Coordsys tool or fail


Description

Glish uses copy-on-write semantics. This sometimes means that it maintains a reference between variables that you would rather it didn't.

This function returns a copy, not a reference, of the Coordsys tool. It is your responsibility to call the done function on the new tool.



Example
- cs := coordsys()
- cs2 := cs             # Reference
- cs.done()
- cs
F
- cs2                   # cs2 gets doned when c2 does
F 
-
- cs := coordsys()
- cs2 := cs.copy()      # Copy
- cs.done()
- cs
F
- cs2
ref [busy=<function>, result=<function>,...   # cs2 is still viable
- cs2.done()
- cs2                   # Now it's done
F





next up previous contents index
Next: coordsys.done - Function Up: coordsys - Tool Previous: coordsys.coordinatetype - Function   Contents   Index
Please send questions or comments about AIPS++ to aips2-request@nrao.edu.
Copyright © 1995-2000 Associated Universities Inc., Washington, D.C.

Return to AIPS++ Home Page
2006-08-01