source: releases/Pester/1.1b7/Source/BDAlias.h@ 567

Last change on this file since 567 was 53, checked in by Nicholas Riley, 22 years ago

Updated for Pester 1.1a5 (very limited release).

Pester 1.1a4 was never released.

File size: 2.8 KB
Line 
1/*
2 Copyright (c) 2001, bDistributed.com, Inc.
3 All rights reserved.
4
5 Redistribution and use in source and binary forms, with or
6 without modification, are permitted provided that the following
7 conditions are met:
8
9 * Redistributions of source code must retain the above
10 copyright notice, this list of conditions and the following
11 disclaimer.
12
13 * Redistributions in binary form must reproduce the above
14 copyright notice, this list of conditions and the following
15 disclaimer in the documentation and/or other materials
16 provided with the distribution.
17
18 * Neither the name of bDistributed.com, Inc. nor the names of
19 its contributors may be used to endorse or promote products
20 derived from this software without specific prior written
21 permission.
22
23 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
24 CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
25 INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
26 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
27 DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE
28 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
29 OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
30 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
31 OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
32 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
33 TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
34 OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
35 OF SUCH DAMAGE.
36*/
37
38#import <Foundation/Foundation.h>
39#import <CoreServices/CoreServices.h>
40
41@interface BDAlias : NSObject
42{
43 AliasHandle _alias;
44}
45
46- (id)initWithAliasHandle:(AliasHandle)alias; // designated initializer
47- (id)initWithData:(NSData *)data;
48- (id)initWithPath:(NSString *)fullPath;
49- (id)initWithPath:(NSString *)path relativeToPath:(NSString *)relPath;
50- (id)initWithFSRef:(FSRef *)ref;
51- (id)initWithFSRef:(FSRef *)ref relativeToFSRef:(FSRef *)relRef;
52
53- (void)dealloc;
54
55- (AliasHandle)alias;
56- (void)setAlias:(AliasHandle)newAlias;
57
58- (NSData *)aliasData;
59- (void)setAliasData:(NSData *)newAliasData;
60
61- (BOOL)aliasIsEqual:(AliasHandle)otherAlias;
62- (BOOL)aliasDataIsEqual:(NSData *)data;
63- (BOOL)isEqual:(id)object;
64
65- (NSString *)displayNameWithKindString:(NSString **)outKindString;
66
67- (NSString *)fullPath;
68- (NSString *)fullPathRelativeToPath:(NSString *)relPath;
69
70+ (BDAlias *)aliasWithAliasHandle:(AliasHandle)alias;
71+ (BDAlias *)aliasWithData:(NSData *)data;
72+ (BDAlias *)aliasWithPath:(NSString *)fullPath;
73+ (BDAlias *)aliasWithPath:(NSString *)path relativeToPath:(NSString *)relPath;
74+ (BDAlias *)aliasWithFSRef:(FSRef *)ref;
75+ (BDAlias *)aliasWithFSRef:(FSRef *)ref relativeToFSRef:(FSRef *)relRef;
76
77@end
Note: See TracBrowser for help on using the repository browser.