mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-30 08:21:25 +00:00
New tool
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@13525 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
b34b39cf6b
commit
6473edaac7
15 changed files with 1934 additions and 2 deletions
63
Tools/make_strings/SourceEntry.m
Normal file
63
Tools/make_strings/SourceEntry.m
Normal file
|
@ -0,0 +1,63 @@
|
|||
/* SourceEntry
|
||||
|
||||
Copyright (C) 2002 Free Software Foundation, Inc.
|
||||
|
||||
Written by: Alexander Malmberg <alexander@malmberg.org>
|
||||
Created: 2002
|
||||
|
||||
This file is part of the GNUstep Project
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
You should have received a copy of the GNU General Public
|
||||
License along with this program; see the file COPYING.LIB.
|
||||
If not, write to the Free Software Foundation,
|
||||
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#include <Foundation/NSObject.h>
|
||||
#include <Foundation/NSString.h>
|
||||
|
||||
#include "SourceEntry.h"
|
||||
|
||||
@implementation SourceEntry
|
||||
|
||||
- initWithKey: (NSString *)k comment: (NSString *)c file: (NSString *)f
|
||||
line: (unsigned int)l
|
||||
{
|
||||
self=[super init];
|
||||
|
||||
ASSIGN(file,f);
|
||||
ASSIGN(comment,c);
|
||||
ASSIGN(key,k);
|
||||
line=l;
|
||||
return self;
|
||||
}
|
||||
|
||||
-(void) dealloc
|
||||
{
|
||||
DESTROY(file);
|
||||
DESTROY(comment);
|
||||
DESTROY(key);
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
|
||||
-(NSString *) description
|
||||
{
|
||||
return [NSString
|
||||
stringWithFormat: @"(key='%@' comment='%@' at '%@':%i)",
|
||||
key,comment,file,line];
|
||||
}
|
||||
|
||||
|
||||
-(NSString *) file { return file; }
|
||||
-(NSString *) comment { return comment; }
|
||||
-(NSString *) key { return key; }
|
||||
-(unsigned int) line { return line; }
|
||||
|
||||
@end
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue