 /**
 Provides structure to a nested object graph such that it can be used in a UITableView or UICollectionView
 */
-public class IMGTree: NSObject, NSCoding {
+public class IMGTree: NSObject, NSCoding, NSCopying {
     
     /**
     Defines the root node which is never displayed on screen but contains the top level nodes

    var isVisible: Bool = false {
        willSet {
            //keep track of prior subtree visibility
            previousVisibleIndex = visibleTraversalIndex()
            if isVisible {
                
                previousVisibleChildren = visibleIndicesForTraversal()
            } else {
                previousVisibleChildren = []

    
    public func encodeWithCoder(aCoder: NSCoder) {
        
    }
    
    //MARK: NSCopying
    
    public func copyWithZone(zone: NSZone) -> AnyObject {
        let treeCopy = IMGTree()
        var rootNodes: [IMGTreeNode] = []
        for node in rootNode.children {
            rootNodes.append(node.copy() as! IMGTreeNode)
        }
        treeCopy.rootNode.children = rootNodes
        return treeCopy
    }
    
    //MARK: DebugPrintable
