public static AfcError afc_get_file_info(AfcClientHandle client, string filename, out System.Collections.ObjectModel.ReadOnlyCollection <string> fileInformation)
        {
            System.Runtime.InteropServices.ICustomMarshaler fileInformationMarshaler = AfcDictionaryMarshaler.GetInstance(null);
            System.IntPtr fileInformationNative = System.IntPtr.Zero;
            AfcError      returnValue           = AfcNativeMethods.afc_get_file_info(client, filename, out fileInformationNative);

            fileInformation = ((System.Collections.ObjectModel.ReadOnlyCollection <string>)fileInformationMarshaler.MarshalNativeToManaged(fileInformationNative));
            fileInformationMarshaler.CleanUpNativeData(fileInformationNative);
            return(returnValue);
        }
        public static AfcError afc_read_directory(AfcClientHandle client, string path, out System.Collections.ObjectModel.ReadOnlyCollection <string> directoryInformation)
        {
            System.Runtime.InteropServices.ICustomMarshaler directoryInformationMarshaler = AfcDictionaryMarshaler.GetInstance(null);
            System.IntPtr directoryInformationNative = System.IntPtr.Zero;
            AfcError      returnValue = AfcNativeMethods.afc_read_directory(client, path, out directoryInformationNative);

            directoryInformation = ((System.Collections.ObjectModel.ReadOnlyCollection <string>)directoryInformationMarshaler.MarshalNativeToManaged(directoryInformationNative));
            directoryInformationMarshaler.CleanUpNativeData(directoryInformationNative);
            return(returnValue);
        }