this repo has no description
at fixPythonPipStalling 119 lines 4.5 kB view raw
1/* 2 * Copyright (c) 2001, 2002, 2004, 2005, 2008, 2012, 2015, 2018 Apple Inc. All rights reserved. 3 * 4 * @APPLE_LICENSE_HEADER_START@ 5 * 6 * This file contains Original Code and/or Modifications of Original Code 7 * as defined in and that are subject to the Apple Public Source License 8 * Version 2.0 (the 'License'). You may not use this file except in 9 * compliance with the License. Please obtain a copy of the License at 10 * http://www.opensource.apple.com/apsl/ and read it before using this 11 * file. 12 * 13 * The Original Code and all software distributed under the License are 14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER 15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, 16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, 17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. 18 * Please see the License for the specific language governing rights and 19 * limitations under the License. 20 * 21 * @APPLE_LICENSE_HEADER_END@ 22 */ 23 24#ifndef _SCDYNAMICSTORECOPYDHCPINFO_H 25#define _SCDYNAMICSTORECOPYDHCPINFO_H 26 27#include <os/availability.h> 28#include <sys/cdefs.h> 29#include <CoreFoundation/CoreFoundation.h> 30#include <SystemConfiguration/SCDynamicStore.h> 31 32CF_IMPLICIT_BRIDGING_ENABLED 33CF_ASSUME_NONNULL_BEGIN 34 35/*! 36 @header SCDynamicStoreCopyDHCPInfo 37 @discussion The functions of the SCDynamicStoreCopyDHCPInfo API 38 provide access to information returned by the DHCP or 39 BOOTP server. 40 */ 41 42 43__BEGIN_DECLS 44 45/*! 46 @function SCDynamicStoreCopyDHCPInfo 47 @discussion Copies the DHCP information for the requested serviceID, 48 or the primary service if serviceID == NULL. 49 @param store An SCDynamicStoreRef representing the dynamic store session 50 that should be used for communication with the server. 51 If NULL, a temporary session will be used. 52 @param serviceID A CFStringRef containing the requested service. 53 If NULL, returns information for the primary service. 54 @result Returns a dictionary containing DHCP information if successful; 55 NULL otherwise. 56 Use the DHCPInfoGetOption function to retrieve 57 individual options from the returned dictionary. 58 59 A non-NULL return value must be released using CFRelease(). 60 */ 61CFDictionaryRef __nullable 62SCDynamicStoreCopyDHCPInfo (SCDynamicStoreRef __nullable store, 63 CFStringRef __nullable serviceID) API_AVAILABLE(macos(10.1)) SPI_AVAILABLE(ios(2.0), tvos(9.0), watchos(1.0), bridgeos(1.0)); 64 65/*! 66 @function DHCPInfoGetOptionData 67 @discussion Returns a non-NULL CFDataRef containing the DHCP 68 option data, if present. 69 @param info The non-NULL DHCP information dictionary returned by 70 calling SCDynamicStoreCopyDHCPInfo. 71 @param code The DHCP option code (see RFC 2132) to return 72 data for. 73 @result Returns a non-NULL CFDataRef containing the option data; 74 NULL if the requested option data is not present. 75 76 The return value must NOT be released. 77 */ 78CFDataRef __nullable 79DHCPInfoGetOptionData (CFDictionaryRef info, 80 UInt8 code) API_AVAILABLE(macos(10.1)) SPI_AVAILABLE(ios(2.0), tvos(9.0), watchos(1.0), bridgeos(1.0)); 81 82/*! 83 @function DHCPInfoGetLeaseStartTime 84 @discussion Returns a CFDateRef corresponding to the lease start time, 85 if present. 86 @param info The non-NULL DHCP information dictionary returned by 87 calling SCDynamicStoreCopyDHCPInfo. 88 @result Returns a non-NULL CFDateRef if lease start time information is 89 present; NULL if the information is not present or if the 90 configuration method is not DHCP. 91 92 The return value must NOT be released. 93 */ 94CFDateRef __nullable 95DHCPInfoGetLeaseStartTime (CFDictionaryRef info) API_AVAILABLE(macos(10.1)) SPI_AVAILABLE(ios(2.0), tvos(9.0), watchos(1.0), bridgeos(1.0)); 96 97 98/*! 99 @function DHCPInfoGetLeaseExpirationTime 100 @discussion Returns a CFDateRef corresponding to the lease expiration time, 101 if present. 102 @param info The non-NULL DHCP information dictionary returned by 103 calling SCDynamicStoreCopyDHCPInfo. 104 @result Returns a non-NULL CFDateRef if the DHCP lease has an expiration; 105 NULL if the lease is infinite i.e. has no expiration, or the 106 configuration method is not DHCP. An infinite lease can be determined 107 by a non-NULL lease start time (see DHCPInfoGetLeaseStartTime above). 108 109 The return value must NOT be released. 110*/ 111CFDateRef __nullable 112DHCPInfoGetLeaseExpirationTime (CFDictionaryRef info) API_AVAILABLE(macos(10.8)) SPI_AVAILABLE(ios(6.0), tvos(9.0), watchos(1.0), bridgeos(1.0)); 113 114__END_DECLS 115 116CF_ASSUME_NONNULL_END 117CF_IMPLICIT_BRIDGING_DISABLED 118 119#endif /* _SCDYNAMICSTORECOPYDHCPINFO_H */