GNUstep CoreBase Library 0.2
CFURLAccess.h
1/* CFURLAccess.h
2
3 Copyright (C) 2012 Free Software Foundation, Inc.
4
5 Written by: Stefan Bidigaray
6 Date: April, 2012
7
8 This file is part of CoreBase.
9
10 This library is free software; you can redistribute it and/or
11 modify it under the terms of the GNU Lesser General Public
12 License as published by the Free Software Foundation; either
13 version 2.1 of the License, or (at your option) any later version.
14
15 This library is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 Lesser General Public License for more details.
19
20 You should have received a copy of the GNU Lesser General Public
21 License along with this library; see the file COPYING.LIB.
22 If not, see <http://www.gnu.org/licenses/> or write to the
23 Free Software Foundation, 51 Franklin Street, Fifth Floor,
24 Boston, MA 02110-1301, USA.
25*/
26
27#ifndef __COREFOUNDATION_CFURLACCESS__
28#define __COREFOUNDATION_CFURLACCESS__
29
30#include <CoreFoundation/CFBase.h>
31#include <CoreFoundation/CFData.h>
32#include <CoreFoundation/CFURL.h>
33
34CF_EXTERN_C_BEGIN
35
42CF_EXPORT const CFStringRef kCFURLFileExists; /* CFBoolean */
43CF_EXPORT const CFStringRef kCFURLFileDirectoryContents; /* CFArray */
44CF_EXPORT const CFStringRef kCFURLFileLength; /* CFNumber */
45CF_EXPORT const CFStringRef kCFURLFileLastModificationTime; /* CFDate */
46CF_EXPORT const CFStringRef kCFURLFilePOSIXMode; /* CFNumber */
47CF_EXPORT const CFStringRef kCFURLFileOwnerID; /* CFNumber */
53CF_EXPORT const CFStringRef kCFURLHTTPStatusCode; /*CFNumber */
54CF_EXPORT const CFStringRef kCFURLHTTPStatusLine; /* CFString */
60typedef enum
61{
62 kCFURLUnknownError = -10,
63 kCFURLUnknownSchemeError = -11,
64 kCFURLResourceNotFoundError = -12,
65 kCFURLResourceAccessViolationError = -13,
66 kCFURLRemoteHostUnavailableError = -14,
67 kCFURLImproperArgumentsError = -15,
68 kCFURLUnknownPropertyKeyError = -16,
69 kCFURLPropertyKeyUnavailableError = -17,
70 kCFURLTimeoutError = -18
71} CFURLError;
74CF_EXPORT Boolean
75CFURLCreateDataAndPropertiesFromResource (CFAllocatorRef alloc, CFURLRef url,
76 CFDataRef *resourceData, CFDictionaryRef *properties,
77 CFArrayRef desiredProperties, SInt32 *errorCode);
78
79CF_EXPORT CFTypeRef
80CFURLCreatePropertyFromResource (CFAllocatorRef alloc, CFURLRef url,
81 CFStringRef property, SInt32 *errorCode);
82
83CF_EXPORT Boolean
84CFURLDestroyResource (CFURLRef url, SInt32 *errorCode);
85
86CF_EXPORT Boolean
87CFURLWriteDataAndPropertiesToResource (CFURLRef url, CFDataRef dataToWrite,
88 CFDictionaryRef propertiesToWrite, SInt32 *errorCode);
91CF_EXTERN_C_END
92
93#endif /* __COREFOUNDATION_CFURLACCESS__ */
94
const struct __CFAllocator * CFAllocatorRef
A reference to a CFAllocator object.
Definition CFBase.h:301
const struct __CFArray * CFArrayRef
Reference to an immutable array object.
Definition CFArray.h:37