• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Objective-C Equivalent of System.currentFullUserName()
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Objective-C Equivalent of System.currentFullUserName()


  • Subject: Re: Objective-C Equivalent of System.currentFullUserName()
  • From: Nicko van Someren <email@hidden>
  • Date: Fri, 9 Apr 2004 14:34:01 +0100

On 9 Apr 2004, at 14:08, Matthew Christensen wrote:

In the cocoa documentation, there is a Java class NSSystem with a method currentFullUserName. Does anyone know what the Objective-C equivalent is? It looks like I can get the login name from [[NSProcess processInfo[ enviroment], but in this particular case I need the full user name.

In Obecjtive-C this is provided by a good, old fashioned function call rather than a method:
NSString *NSFullUserName(void);
The prototype is in <Foundation/NSPathUtilities.h> but this should just be included already if you've included <Foundation/Foundation.h> or the AppKit headers. It's listed in the "Path utilities" section of the foundation functions documentation. See the link below.

Nicko

http://developer.apple.com/Documentation/Cocoa/Reference/Foundation/ ObjC_classic/Functions/FoundationFunctions.html#//apple_ref/doc/uid/ 20000055/BCIJCEFC
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Objective-C Equivalent of System.currentFullUserName() (From: Matthew Christensen <email@hidden>)

  • Prev by Date: Re: delegate outlet
  • Next by Date: Re: Objective-C Equivalent of System.currentFullUserName()
  • Previous by thread: Objective-C Equivalent of System.currentFullUserName()
  • Next by thread: Re: Objective-C Equivalent of System.currentFullUserName()
  • Index(es):
    • Date
    • Thread