Exemplo n.º 1
0
Arquivo: gdal.go Projeto: colek42/gdal
// Copy all files associated with the named dataset
func (driver Driver) CopyDatasetFiles(newName, oldName string) error {
	cDriver := driver.cval
	cNewName := C.CString(newName)
	defer C.free(unsafe.Pointer(cNewName))
	cOldName := C.CString(oldName)
	defer C.free(unsafe.Pointer(cOldName))
	return C.GDALCopyDatasetFiles(cDriver, cNewName, cOldName).Err()
}
Exemplo n.º 2
0
Arquivo: gdal.go Projeto: kikht/gdal
// Copy all files associated with the named dataset
func (driver Driver) CopyDatasetFiles(newName, oldName string) error {
	cDriver := driver.cval
	cNewName := C.CString(newName)
	defer C.free(unsafe.Pointer(cNewName))
	cOldName := C.CString(oldName)
	defer C.free(unsafe.Pointer(cOldName))
	err := C.GDALCopyDatasetFiles(cDriver, cNewName, cOldName)
	if err != 0 {
		return error(err)
	}

	return nil
}