Esempio n. 1
0
    def copyone(self, src, dst, overwrite):
        """ copy one resource with Depth=0

        an alternative implementation would be

        result_code=201
        if overwrite:
            result_code=204
            r=os.system("rm -f '%s'" %dst)
            if r: return 412
        r=os.system("cp '%s' '%s'" %(src,dst))
        if r: return 412
        return result_code

        (untested!). This would not use the davcmd functions
        and thus can only detect errors directly on the root node.
        """
        res = copyone(self, src, dst, overwrite)
        return res
Esempio n. 2
0
    def copyone(self, src, dst, overwrite):
        """ copy one resource with Depth=0

        an alternative implementation would be

        result_code=201
        if overwrite:
            result_code=204
            r=os.system("rm -f '%s'" %dst)
            if r: return 412
        r=os.system("cp '%s' '%s'" %(src,dst))
        if r: return 412
        return result_code

        (untested!). This would not use the davcmd functions
        and thus can only detect errors directly on the root node.
        """
        res=copyone(self, src, dst, overwrite)
        return res
Esempio n. 3
0
    def copyone(self, src, dst, overwrite):
        """ copy one resource with Depth=0
        """

        return copyone(self, src, dst, overwrite)
Esempio n. 4
0
 def copyone(self, src, dst, overwrite):
     return copyone(self, src, dst, overwrite)
Esempio n. 5
0
    def copyone(self,src,dst,overwrite):
        """ copy one resource with Depth=0
        """

        return copyone(self,src,dst,overwrite)
Esempio n. 6
0
 def copyone(self, src, dst, overwrite):
     return copyone(self, src, dst, overwrite)