def setLayer(self, layer):
        """
        Sets the layer that this node is associated with to the given layer.
        
        :param      layer       | <XNodeLayer> || None
        
        :return     <bool> changed
        """
        if layer == self._layer:
            return False

        self._layer = layer
        self.syncLayerData()

        return True
def setLayer ( self , layer ) : if layer == self . _layer : return False self . _layer = layer self . syncLayerData ( ) return True
Sets the layer that this node is associated with to the given layer.
        
        :param      layer       | <XNodeLayer> || None
        
        :return     <bool> changed