Main Page
    Cookbook/Overview     ImageMeister     the jcprops file     Licensing
    Binary Installation & Configuration [ Win · Mac · Nix · OSX ]     Changes
    Public API
    Source Code Main Page
        Java [ Common · Win · Mac · Nix ]     Native Code [ Common · Win · Mac · Nix ]     Manifest
        Native Code Overviews [ Common · Win · Mac · Nix · Strings ]     Macros [ General · Native Macros ]
        Walkthroughs [ Java only · Java and native ]     Building [ Win · Mac · Nix · OSX ]     Distribution Issues

All Packages  This Package  Class Hierarchy  Class Search  Index

Class com.jconfig.mac.AppFinderMRJ
java.lang.Object
   |
   +----com.jconfig.mac.AppFinderMRJ

  Summary

class  AppFinderMRJ
     extends java.lang.Object
{
          // Fields 3
     private static final String copyrightString;
     private static final int kFindAPPLMultipleMaxNameLen;
     private static IToolboxLock lockObject;

          // Constructors 1
     AppFinderMRJ(File, int);

          // Methods 10
     private static int call_nFindAPPLMultiple(int, int[], int[], byte[], int, int, int[]);
     private static int call_nFindAPPLSingle(int, int[], byte[], int);
     static IToolboxLock getLockObject();
     private static native int nFindAPPLMultiple(int, int[], int[], byte[], int, int, int[]);
     private static native int nFindAPPLSingle(int, int[], byte[], int);
     static void setLockObject(IToolboxLock);
     static void testLink();

     public AppFile[] findAPPL(int, int, int);
     private AppFile[] findAPPLMultiple(int, int, int);
     private AppFile[] findAPPLSingle(int, int);
}

Used to find applications given a creator code (e.g., 'MSWD'). Calls native code to do most of the work.

Author:
Copyright (c) 1997-2002 Samizdat Productions. All Rights Reserved.




  Fields

· copyrightString

Summary  |  Top

   private static final String copyrightString


· kFindAPPLMultipleMaxNameLen

Summary  |  Top
   private static final int kFindAPPLMultipleMaxNameLen


· lockObject

Summary  |  Top
   private static IToolboxLock lockObject


  Constructors

· AppFinderMRJ

Summary  |  Top

   AppFinderMRJ(File curDir, 
                int creator) 

Currently does nothing. The arguments have the same significance as those to the FileRegistry.initialize() method.



  Methods

· setLockObject

Summary  |  Top
   static void setLockObject(IToolboxLock lock) 


· getLockObject

Summary  |  Top
   static IToolboxLock getLockObject() 


· findAPPL

Summary  |  Top
   public AppFile[] findAPPL(int creator, 
                             int maxToReturn, 
                             int flags) 

Searches for one or more applications with the given creator code.

Parameter Description
maxToReturn if this is 1, calls findAPPLSingle. Otherwise, calls findAPPLMultiple.
creator the creator of the application to search for.
flags the search level, defined in FileRegistry: GETAPPS_SEARCH1, etc. 0 means no searching, any other value means do a search Of course, searching takes longer than values cached in the desktop database. However, searching may be an alternative to suggesting the user rebuilds their desktop.



· findAPPLSingle

Summary  |  Top
   private AppFile[] findAPPLSingle(int creator, 
                                    int flags) 

Find one app with the given creator. Calls call_nFindAPPLSingle, and creates an AppFile if an app was found.

Parameter Description
creator the app's creator
flags see findAPPL()



· findAPPLMultiple

Summary  |  Top
   private AppFile[] findAPPLMultiple(int creator, 
                                      int maxToReturn, 
                                      int flags) 

Find more than one copies of an app with the given creator. Calls call_nFindAPPLMultiple to do the work.

Parameter Description
creator the creator of the app
maxToReturn the maximum number of apps to find
flags see findAPPL()



· call_nFindAPPLSingle

Summary  |  Top
   private static int call_nFindAPPLSingle(int creator, 
                                           int[] vRefAndParID, 
                                           byte[] pName, 
                                           int flags) 


· call_nFindAPPLMultiple

Summary  |  Top
   private static int call_nFindAPPLMultiple(int creator, 
                                             int[] vRefs, 
                                             int[] parIDs, 
                                             byte[] pNames, 
                                             int maxToReturn, 
                                             int flags, 
                                             int[] numReturned) 


· nFindAPPLSingle

Summary  |  Top
   private static native int nFindAPPLSingle(int creator, 
                                             int[] vRefAndParID, 
                                             byte[] pName, 
                                             int flags) 

Find one matching app.

Parameter Description
creator the app's creator
vRefAndParID the app's vRef will be placed at vRefAndParID[ 0 ], and the parID will be placed at vRefAndParID[ 1 ]
pName the app's name will be placed in this array as a Pascal string. Must have at least AppUtilsMRJ.kPNameLen elements.
flags currently this value is ignored



· nFindAPPLMultiple

Summary  |  Top
   private static native int nFindAPPLMultiple(int creator, 
                                               int[] vRefs, 
                                               int[] parIDs, 
                                               byte[] pNames, 
                                               int maxToReturn, 
                                               int flags, 
                                               int[] numReturned) 

Find multiple matching app.

Parameter Description
creator the app's creator
vRefs each app's vRef will be placed at successive locations in this array
parIDs each app's parID will be placed at successive locations in this array
pName each app's name will be placed at successive locations in this array as a Pascal string. Each name will consume kFindAPPLMultipleMaxNameLen elements, and this array must have at least (kFindAPPLMultipleMaxNameLen * maxToReturn) elements
maxToReturn the maximum number of apps to return
flags currently, if this is 0 only standard searching is performed. if this is not zero, a more extensive search is performed.
numReturned the number of apps returned will be placed at numReturned[ 0 ]



· testLink

Summary  |  Top
   static void testLink() 

Calls each of the native methods with invalid arguments. Used to test if there are link problems.



All Packages  This Package  Class Hierarchy  Class Search  Index
Freshly brewed Java API Documentation automatically generated with polardoc Version 1.0.7