Creating a package name questions.

If I want to put all my classes in a package called:
package com.xxx.yyy.zzzz;
Can I use com? Is com like a reserved name? Where would I place xxx?

packages should correspond with your domain name, so if you own a .com (say [url http://forum.java.sun.com/thread.jsp?forum=53&thread=399128&tstart=0&trange=15]weLoveTheForumAdmin.com), then you package would be
package com.welovetheforumadmin.<whatever you want>;
if you own a .tk or .gb or .uk, it would change approperatly.
If you don't own a domain name, then you could use your website url (say you have a geocities account called [url http://forum.java.sun.com/thread.jsp?forum=53&thread=399128&tstart=0&trange=15]welovetheforumadmin , then you could use
package com.geocities.welovetheforumadmin.<what everyour want>;
(or get a free domain/sub domain from say from [url http://www.dot.tk/].tk or [url http://www.no-ip.com/]No IP.
If you have no web pressence, its acceptable to place under something that is not, and never will be a TLD, eg
package we_love_the_forum_admin.<what ever you want>;
However, NEVER put anything in the java, javax or com.sun name spaces.
It should be noted that not [url http://www.microsoft.com]everyone [url http://classpath.org]one follows these rules.
(Microsoft not only puts stuff in the java name space, but also under the com.ms namespace (Morgan Stanley), while Classpath buts its plateform dependent stuff in the gnu namespace, not org.gnu, while many people don't care it becomes a problem if say both morgan stanley and MS release a com.ms.WeLoveTheForumAdmin class).

Similar Messages

  • How to create "package name" for transport request

    Hi experts
    I am trying to create transport request for infopackage/data source/dtp etc...
    but system is asking package name in object directory entery.
    Could you pl. share the information step by step, how to create the "package name"
    Thanks in advance and you can get valuble points pl.
    Chandu

    Hi,
    Go to transaction SE21 and give the package name as ZAPO or any thing starts with Z.
    click on create button.
    give a short description
    in the Package properties block- allowed object types list box - select No restrictions.
    in the transport attributes block- specify the transport layer
    give software component as HOME
    select the check box for changes recorded.
    save the package.
    or
    Go to SE80
    select package from the list box
    give your package name and hit enter button
    the popup asks you for input.
    give the appropriate values and press create button.
    Note: You should be registered as a developer in the system where you are creating the package.
    Hope this solves your problem, Good luck
    Srini

  • Changing Package Name of an AIR apk

    Hi. I have created an AIR app that is currently in the market. To update the app, obviously I must keep the same package name. My first version's were packaged using Eclipse with the ADT plugin.
    Now to use AIR 3.0 Native Extensions (ANE) which were not available when I first developed the app, I currently must create my APK using AIR's command line tools. Unfortunately, these command line tools force you to have a package name that starts with the word "air". For example, I need the package name "com.example". AIR creates the package name as "air.com.example".
    So now, I cannot update my app in the market since the package name has changed. Adobe has this horrific article to help you rename and remove the "air" in the package. I'm not a great programmer so this has really stumped me.
    http://kb2.adobe.com/cps/875/cpsid_87562.html
    Apparently this info is out of date or incorrect in a few areas.
    I have completely stumbled at step 12 which uses apkbuilder:
    apkbuilder final.apk -u -z resources.arsc -f classes.dex
    I am getting this error message:
    THIS TOOL IS DEPRECATED. See --help for more information.
    java.io.FileNotFoundException: resources.arsc does not exist
    I have used step 10 to create the new resources.arsc file. It clearly DOES exist and in the correct location. I tried using apkbuilder with other resources.arsc files taken from other projects. I still get the same error message.
    Maybe there is another way to do this using another tool like like apkTool. http://code.google.com/p/android-apktool/
    I tried this but then couldn't get jarsigner to sign the apk properly.
    Is there a chance in hell of this working? There doesn't seem to be much about this topic on the internet. If anyone is interested in this, I have a zip file with a sample AIR apk, windows bat files for all the command line work, and all the needed utilities so they don't need to be downloaded. To get started you just need to change my path.bat to fit your system. And you need notepad++ (or an equivalent) to batch automate renaming the package name across several files.
    http://bradwallacedesign.com/dktimer/renameApkProject.zip
    Thanks so much!

    If the DisplayObject is on the timeline then its name cannot
    be modified, but the name property of dynamically created
    DisplayObjects can be changed. (DisplayObject.name:String
    read/write).

  • Deleting package names in TDMS as well as Project and subpro

    Hi All,
      I created project name and description and inside the project i created a subproject and given its description and inside the subproject i created a package name in <b>TDMS</b> .
    Just i created the names only. Now i want to delete these all and to create new one. I dont want this to be listed in the tcode cnv_mbt_tdms_my.
    When i tried to delete the package first, it is not allowing to delete.
    and also there is no option for deleting the package.
    How to delete these project, subproject and packages in TDMS.?

    Hello,
    Note 1030483 contains some information on how to ddelete TDMS package accordinglingly in releases TDMS 2005 and TDMS 2006. Additionally the package deletion has been integrated now into TDMS overview Transaction CNV_MBT_TDMS_MY in the package menu with DMIS SP4 .
    Best regards,
    Peter

  • Creating Packages Recource Name Question

    I am trying to create a package combining the data grim a LightSwitch control. I have the following code in my application folder. but I don't know what to put in for the string ResourceName. I am trying to add this data to the excel Zip file in a way that
    it "creates" the table overwriting the current sheet1 and replacing it with one that has the Data From the Entity/Silverlight screen's grid which is filter by another table selecting the orders for a person. I get a Null not handled exception I believe
    because I am not address the resource right. Also were am I supposed to put the reference to the filtered Grid I am trying to access I am very new at building packages this way. also note there is code to Open(process Start) the other excel file but I can't
    seem to place it so it fires after the code for building the package runs this is necessary because the Process started package has links to the book1 I am trying to build.
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.IO.IsolatedStorage;
    using Microsoft.LightSwitch;
    using Microsoft.LightSwitch.Security.Server;
    using Microsoft.LightSwitch.Framework.Server;
    using System.IO;
    using System.IO.Packaging;
    using System.Reflection;
    //added this to allow the process statement that opens excel
    using System.Diagnostics;
    using System.Linq.Expressions;
    namespace LightSwitchApplication
    public partial class ApplicationDataService
    private string _PackageName = "Book1.xlsx";
    partial void Commands_Inserting(Command entity)
    switch (entity.Argument)
    case "CreateDocument":
    //This opens the excel file from the current directory
    Process.Start("MAR mod1.1.xlsx");
    entity.Result = _PackageName;
    //Package, file name and Uri location
    Package package = Package.Open(_PackageName, FileMode.Open);
    Uri uri = new Uri("/xl/worksheets.sheet1", UriKind.Relative);
    //Content Type for Each Part
    PackagePart DocPart = package.CreatePart(uri, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml");
    string ResourceName = "Book1.xlsx.zip/xl/worksheets/sheet1.xml";
    Assembly ResourceAssembly = Assembly.GetExecutingAssembly();
    using (Stream DocPartStream = DocPart.GetStream(FileMode.Create))
    using (Stream DocSourceStream = ResourceAssembly.GetManifestResourceStream(ResourceName))
    DocSourceStream.CopyTo(DocPartStream);
    package.CreateRelationship(uri, TargetMode.Internal, "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument", "rID1");
    package.Close();
    break;
    Exception Detail
    System.NullReferenceException was unhandled by user code
      HResult=-2147467261
      Message=Object reference not set to an instance of an object.
      Source=Application.Server
      StackTrace:
           at LightSwitchApplication.ApplicationDataService.Commands_Inserting(Command entity)
           at LightSwitchApplication.ApplicationDataService.DetailsClass.__Commands_Inserting(ApplicationDataService d, Command e)
           at Microsoft.LightSwitch.Details.Framework.Server.EntitySetEntry`2.Microsoft.LightSwitch.Details.Framework.Server.IEntitySetEntry.InvokeInserting(IDataService dataService, IEntityObject entity)
           at Microsoft.LightSwitch.ServerGenerated.Implementation.DataServiceImplementation`1.<>c__DisplayClass40.<PerformPreEvent>b__3a(IEntitySetEntry entitySetEntry)
           at Microsoft.LightSwitch.ServerGenerated.Implementation.DataServiceImplementation`1.<>c__DisplayClass43.<CallPrePostUserCode>b__42()
           at Microsoft.LightSwitch.Utilities.Internal.UserCodeHelper.CallUserCode(Type sourceType, String methodName, String instance, String operation, ILoggingContext context, Action action, String additionalText, Func`1 getCompletedMessage,
    Boolean tryHandleException, Boolean swallowException, Exception& exception)
      InnerException:

    Thanks I have been doing research watching following video and this is my updated code in application.cs. I got the resource into my project manually by copying the whole zip file contents into the project file and then in file view I deleted and rebuilt
    the xml resource sheet 13 making it an embedded resource and left the rest of the package alone.
    video
    //This is what I have on the ApplicationData.cs end of things
    private string _PackageName = "Book1.xlsx";
    partial void Commands_Inserting(Command entity)
    switch (entity.Argument)
    case "CreateDocument":
    //This opens the excel file from the current directory
    Process.Start("MAR mod1.1.xlsx");
    entity.Result = _PackageName;
    //Package, file name and Uri location
    Package package = Package.Open(_PackageName, FileMode.Open);
    Uri uri = new Uri("/xl/worksheets.sheet13", UriKind.Relative);
    //Content Type for Each Part
    PackagePart DocPart = package.CreatePart(uri, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml");
    string ResourceName = "Patient Records.Server.Package.xl.worksheets.sheet13.xml";
    /*"Book1.xlsx/xl/worksheets/sheet1.xml";*/
    Assembly ResourceAssembly = Assembly.GetExecutingAssembly();
    int buffer;
    using (Stream DocPartStream = DocPart.GetStream(FileMode.Open))
    using (Stream DocSourceStream = ResourceAssembly.GetManifestResourceStream(ResourceName))
    buffer = DocSourceStream.ReadByte();
    while (buffer != -1)
    DocPartStream.WriteByte((byte)buffer);
    buffer = DocSourceStream.ReadByte();
    package.CreateRelationship(uri, TargetMode.Internal, "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet", "rId13");
    package.Close();
    //opens the new package
    Process.Start("Book1.xlsx");
    break;

  • How to create package name  what is the transaction code for creation

    Hi,
    I want to create the package and also put that package in my program, how to put the package already saved program.

    Hello Rajyalakshmi
    You do not put a package to or into a program but <b>ASSIGN </b>a report to a package. To reassign a report to a new package (e.g. from $TMP to z-package) call transaction SE80 and right-click on the report name in the tree display. Choose the following function in the context menu:
    Other Functions -> Change Package Assignment
    Regards
      Uwe

  • Quick Question: package names com.whatever.blah.ClassName

    I want to put a bit more time aside this week to explain things I see in Java to my old brain (I don't quite 'get it' like you younger people :-))
    I often see things like this in example code:
    import com.macfaq.io.SafeBufferedReader;and it's crossed my mind I don't understand this.
    My guess is that the program concerned is going to look for a class called SafeBufferedReader. My confusion is twofold;
    1: I'm guessing I would need to locate this class/library: com.macfaq.io.SafeBufferedReader; (probably from macfaw.com)
    2: I'm more interested to know wow would I structure the directories in relation to the main script to deal with this naming context? Would it be:
    /root {contains main program}
    /root/com/macfaq/io/ {which would contain SafeBufferedReader}
    This kind of thing appears to be missing from the basic tutorials I've looked at and appears to be 'assumed' knowledge :-)

    My guess is that the program concerned is going to look for a class called SafeBufferedReader.Well there's nothing else it could mean.
    1: I'm guessing I would need to locate this class/library: com.macfaq.io.SafeBufferedReader; (probably from macfaw.com)Correct.
    2: I'm more interested to know wow would I structure the directories in relation to the main script to deal with this naming context? Would it be:
    /root {contains main program}No. /root/your/package/name/whatever contains your.package.name.whatever.MainProgram. You shouldn't be writing classes that aren't in a package.
    /root/com/macfaq/io/ {which would contain SafeBufferedReader}No. You will be downloading a .jar file that contains that class.
    This kind of thing appears to be missing from the basic tutorials I've looked at and appears to be 'assumed' knowledge :-)See the General Information here.

  • Bc4j Package Path/name Question

    I am using this below mentioned package name, I just want to make sure my customizations are free from PATCHes.
    oracle.apps.pay.xxxabc....
    is it going to be ok? Please help.

    You should use xxYOURCOMPANYIDENTIFIER.oracle.apps.pay....
    --Shiv                                                                                                                                                                                           

  • Create folder with name Client150412n

    Hi,
    I'm new to ApplesScripting. I've found this script that I'd like to change:
    --This script will make a new folder on the desktop with current date and dialog box
    --format the date to 2010-11-19
    tell (current date) to get day & (it's month as integer) & (it's year as integer)
    set TheDateFormat to the result as text
    -- asks for folder name with date as default answer
    set TheFolderName to text returned of (display dialog "Name the folder" default answer TheDateFormat)
    --make folder with date & user entered text
    tell application "Finder"
      make new folder with properties {name:TheFolderName}
    end tell
    The desired changes:
    - Date format should be: 150412 + a letter (a, b, c) if the folder to be created already exists.
    - Place the cursor at the start of name dialog, no selection active.
    - The new folders should be created in /Users/Hans/Dropbox/Jobs/
    Thanks,
    Hans
    Another question is related to execution of the script:
    - How can I start the script easily with a shortcut key or a Dock icon?
    - Is it possible to select client name from a plain text file containing client names in separate lines?
    - Is it possible to have zip files automatically unzipped to subfolder names with the zip package name?
    - Regarding the Dock icon I could even imagine that I drag a zip or other file from an email or the Desktop to the icon and that I only have to type the clients name to have the file moved to a new folder.

    save script as an application bundle.  Drag app to dock.
    Set short-cut key to app.
    AppleScript   Learn AppleScript: The Comprehensive Guide to Scripting and Automation on Mac OS X, Third Edition the book
    AppleScript Language Guide pdf download the pdf file

  • Package Names

    This is another of my questions related with naming. My problem is that I care so much on naming of packages, classes, methods, variables, etc because I want to make my code as readable as possible.
    I read from google about some standards when creating a new package. It states that it must the company domain in reverse. This means "com.companyname.xxxx" or "org.organizationname.xxxx" like "org.eclipse.xxxx" or "com.nokia.xxxx". So far so good...
    My problems comes when I have to devide the application classes. I most often use the MVC. so what I do is having
    org.organizationname.applicationname.view
    org.organizationname.applicationname.control
    org.organizationname.applicationname.model
    org.organizationname.applicationname.utilHowever I am finding this a little stupid. My problem is I never seen any full application code and so I had to invent these myself. I sometimes change from .control to .business or .services.
    My question is how do you usually name the packages to identify between the view, model, control classes??
    I also get confused on how to set the package name for an application that will make use of a webservice. Because a webservice is a service, but you could have other things that can be a service. And you can not make your package name too long either!!

    This is another of my questions related with naming.
    My problem is that I care so much on naming of
    f packages, classes, methods, variables, etc because
    I want to make my code as readable as possible.
    I read from google about some standards when creating
    a new package. It states that it must the company
    domain in reverse. This means "com.companyname.xxxx"
    or "org.organizationname.xxxx" like
    "org.eclipse.xxxx" or "com.nokia.xxxx". So far so
    good...
    "Must" is a very strong word. I believe "recommends" is more correct. We use the reversed URL convention for package names where I work, but it's not mandatory.
    My problems comes when I have to devide the
    application classes. I most often use the MVC. so
    what I do is having
    org.organizationname.applicationname.view
    org.organizationname.applicationname.control
    org.organizationname.applicationname.model
    org.organizationname.applicationname.util
    However I am finding this a little stupid. What's so stupid? That's the way I see it done.
    I think it's only a problem if (1) you can't touch type, (2) you don't have an IDE like IntelliJ that can automatically insert the package name for you when create a class in a package, or (3) you're bothered by a bit of verbosity.
    My
    problem is I never seen any full application code and
    so I had to invent these myself. I sometimes change
    from .control to .business or .services.
    My question is how do you usually name the packages
    to identify between the view, model, control
    classes??Yes.
    I also get confused on how to set the package name
    for an application that will make use of a
    webservice. Because a webservice is a service, but
    you could have other things that can be a service.Every service is not a web service - two different things. It's a packaging/deployment issue. The fact that you choose to deploy a particular service as a Web service doesn't change its essence.
    And you can not make your package name too long
    g either!!What do you mean by "too long"?
    Do you have a point or a question here?
    %

  • Hardcoded wrong DefaultRealmImpl package name

    I posted it twice in weblogic.developer.interest.security, but nobody
    from BEA answered. If it's a bug just admit it and say how to workaround
    it if possible. Plase help.
    In article <[email protected]>, [email protected]
    says...
    l> I have been getting the java.lang.ClassNotFoundException:
    l> weblogic.security.acl.DefaultRealmImpl.
    Are you upgrading from an earlier version of WLS to 5.1? If so, you
    should not be using DefaultRealmImpl any more.
    Hi, I have exactly the same problem. I not upgrading, I use 5.1 sp5. And
    it's not me who's trying to load DefaultRealmImpl with the wrong package
    name:
    java.lang.ClassNotFoundException: weblogic.security.acl.DefaultRealmImpl
    at weblogic.boot.ServerClassLoader.findLocalClass
    (ServerClassLoader.java:355)
    at weblogic.boot.ServerClassLoader.loadClass
    (ServerClassLoader.java:111)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:120)
    at weblogic.security.acl.Realm.getRealm(Realm.java:79)
    at weblogic.security.acl.Realm.getRealm(Realm.java:31)
    at com.gocargo.jwasp.core.user.UserEJBBean.isInRole
    (UserEJBBean.java:437)
    at com.gocargo.jwasp.core.user.UserEJBBeanEOImpl.isInRole
    (UserEJBBeanEOImpl.java:755)
    at com.gocargo.jwasp.core.user.UserEJBBeanEOImpl_WLSkel.invoke
    (UserEJBBeanEOImpl_WLSkel.java
    at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke
    (BasicServerObjectAdapter.java:347
    at weblogic.rmi.extensions.BasicRequestHandler.handleRequest
    (BasicRequestHandler.java:69)
    at weblogic.rmi.internal.BasicExecuteRequest.execute
    (BasicExecuteRequest.java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    As far as I understand, the problem is that somebody hardcoded the wrong
    package name of the DefaultRealmImpl (it should be
    weblogic.security.acl.internal.DefaultRealmImpl).
    Question: inside my code I use this line to get RDMBS realm:
    RDBMSRealm realm = (RDBMSRealm)Realm.getRealm
    (RDBMSRealm.REALM_NAME);
    The constructor of RDMBS realm uses super(REALM_NAME). Maybe I should
    use some other name? If you create DefaultRealmImpl in case you can't
    find the specified realm, just tell me how to correctly find/register
    custom realm. I tried passing fully qualified name of the realm class,
    but it didn't help.
    Bea, please help.
    Thank you.
    Roman.

    Hi Roman,
    I got the same odd exception trying to implement a custom realm using an
    own UserInfo. The simple but ridiculous solution for me was to make
    UserInfo.getRealmName() return "weblogic" instead of the real realm
    name.
    It's astonishing how sedansly BEA reacts on this error, since it often
    occurs in the newsgroups.
    Bodo.
    Roman Stepanenko wrote:
    >
    I posted it twice in weblogic.developer.interest.security, but nobody
    from BEA answered. If it's a bug just admit it and say how to workaround
    it if possible. Plase help.
    In article <[email protected]>, [email protected]
    says...
    l> I have been getting the java.lang.ClassNotFoundException:
    l> weblogic.security.acl.DefaultRealmImpl.
    Are you upgrading from an earlier version of WLS to 5.1? If so, you
    should not be using DefaultRealmImpl any more.
    Hi, I have exactly the same problem. I not upgrading, I use 5.1 sp5. And
    it's not me who's trying to load DefaultRealmImpl with the wrong package
    name:
    java.lang.ClassNotFoundException: weblogic.security.acl.DefaultRealmImpl
    at weblogic.boot.ServerClassLoader.findLocalClass
    (ServerClassLoader.java:355)
    at weblogic.boot.ServerClassLoader.loadClass
    (ServerClassLoader.java:111)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:120)
    at weblogic.security.acl.Realm.getRealm(Realm.java:79)
    at weblogic.security.acl.Realm.getRealm(Realm.java:31)
    at com.gocargo.jwasp.core.user.UserEJBBean.isInRole
    (UserEJBBean.java:437)
    at com.gocargo.jwasp.core.user.UserEJBBeanEOImpl.isInRole
    (UserEJBBeanEOImpl.java:755)
    at com.gocargo.jwasp.core.user.UserEJBBeanEOImpl_WLSkel.invoke
    (UserEJBBeanEOImpl_WLSkel.java
    at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke
    (BasicServerObjectAdapter.java:347
    at weblogic.rmi.extensions.BasicRequestHandler.handleRequest
    (BasicRequestHandler.java:69)
    at weblogic.rmi.internal.BasicExecuteRequest.execute
    (BasicExecuteRequest.java:15)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:135)
    As far as I understand, the problem is that somebody hardcoded the wrong
    package name of the DefaultRealmImpl (it should be
    weblogic.security.acl.internal.DefaultRealmImpl).
    Question: inside my code I use this line to get RDMBS realm:
    RDBMSRealm realm = (RDBMSRealm)Realm.getRealm
    (RDBMSRealm.REALM_NAME);
    The constructor of RDMBS realm uses super(REALM_NAME). Maybe I should
    use some other name? If you create DefaultRealmImpl in case you can't
    find the specified realm, just tell me how to correctly find/register
    custom realm. I tried passing fully qualified name of the realm class,
    but it didn't help.
    Bea, please help.
    Thank you.
    Roman.

  • About package name and transport request number

    Hello Gurus,
            I know when doing some changes in the sap bw system, and performing activation subsequently , you are prompted to save the changes into some package and transport request. my question is:
            in the real project, where does those package name and transport request number come from?   make up by myself or provided by project management, or someone else?  if doing by youself, how to make up package name and transport request number ?
    Many thanks.

    package is like a folder in windows.. u create package for a project and than collect all the relevant transports in it.
    to create package u use SE80.. Transport req number are configured by basis team.. its usually source system ID and running serial number...
    package name can be decided by tech architect or by ur team manager..

  • JDeveloper Addin - Get Package Name

    I'm creating a new Wizard addin for JDeveloper that basically does the same thing as creating a new java file, however it will create the JavaSourceNode with content from a template using my companies coding standards.
    My question / problem is that I can't figure out how to get the package name from JDeveloper to display in my JDialog similar to how creating a new java file works.
    When creaing a new java file, you can select a package and click new and the package name that displays in the dialog is that package name.
    Can any one suggest how to get the package name in the same manner that creating a new java file works?

    Here is the code that I came up with that I think fits with creating a new java file;
    public String getPackageName(Context context) {
    JProject jProject = (JProject)context.getProject();
    String packageName = null;
    // Get a selected element
    Element element = context.getElement();
    // If element is not NULL and is of instance of PackageFolder then
    // set the packageName to the selected package.
    if ((element != null) && (element instanceof PackageFolder)) {
    // Set the packageName to the package that was selected
    packageName = element.getShortLabel();
    } else {
    // If no package was selected then try to get the first package
    // entry of the <defaultPackages> element of the jpr. If there
    // are no packages then just use the default jpr package
    // name.
    if (!(jProject.getDefaultPackages().isEmpty())) {
    packageName = (String)jProject.getDefaultPackages().get(0);
    } else {
    packageName = jProject.getDefaultPackage();
    } // end if not empty
    } // end if
    return packageName;
    } // getPackageName
    The plugin that you suggested is very cool, but a little different that what I'm trying to do.

  • I need to remove "air." from package name. I'm get a Layout xml error when repackaging android app..

    So, i'm doing this on my own app. I made an update for an older app that was build using Native Android. But this time, i used Adobe AIR... The catch is Adobe likes to append a "air." to the front of your package name without asking you. So basically I can't upload my update because it has a new package name is now "air.com.mycompany.myapp" rather than the original "com.mycompany.myapp"
    Basically I'm going through this guide..
    http://helpx.adobe.com/air/kb/opt-out-air-application-analytics.html
    I followed all the steps, made all the adjustments to the androidmanifest.xml like it asks.
    But after going along with the above guide, with no issues when i get to the step that says
    "Run the following command to create the resource file for the updated AndroidManifest.xml:"
    I run this..
        "/Users/brybam/Documents/eclipse/android-sdk-mac_x86/platform-tools/aapt" package -f -M AndroidManifest.xml -F resources.arsc -I "/Users/brybam/Documents/eclipse/android-sdk-mac_x86/platforms/android-8/android.jar" -S ./res
    But I keep getting the same error regarding the xml files in res/layout
        ./res/layout/expandable_chooser_row.xml:1: error: Error parsing XML: not well-formed (invalid token)
        ./res/layout/expandable_multiple_chooser_row.xml:1: error: Error parsing XML: not well-formed (invalid token)
        ./res/layout/main.xml:1: error: Error parsing XML: not well-formed (invalid token)
        ./res/layout/multiple_file_selection_panel.xml:1: error: Error parsing XML: not well-formed (invalid token)
        ./res/layout/ssl_certificate_warning.xml:1: error: Error parsing XML: not well-formed (invalid token)
    The guide doesn't say anything about these xml files, and im not sure what to do with these or how to handle them.
    If i go into the res/layout folder, and just delete these (i know they're necessary. But i just deleted them as a test, to get through the rest of the guide...)
    I was able to get through the rest of the steps in the guide fine, make an apk, and put it on my phone...only to find out the app will crash the moment you try to run it. Probably because i deleted the layout xml files...But i cant get the command i need to run above to accept them!
    So, earlier in the guide they have me use thing thing called the "AXMLPrinter2.jar" to make the AndroidManifest.xml readable so i can edit it.
    I run something like this:
        java -jar "/Users/brybam/Desktop/repackage/AXMLPrinter2.jar" AndroidManifest.xml > AndroidManifest.xml.bk
    This makes a new file "AndroidManifest.xml.bk" and i can edit that.
    So, I was thinking with all of these layout xml files, maybe I could run this "AXMLPrinter2.jar" on them and then edit them. Because right now if you open them they're not human readable, and its hard for me to work on them if they're not...
    I tried this thinking i could do the same thing...
        java -jar "/Users/brybam/Desktop/repackage/AXMLPrinter2.jar" main.xml > main.xml.bk
    Just get a blank file and a console erorr when trying to use the AXMLPrinter2.jar on the layout xml files...
        java.lang.ArrayIndexOutOfBoundsException: 67
                  at android.content.res.StringBlock.getShort(StringBlock.java:231)
                  at android.content.res.StringBlock.getString(StringBlock.java:91)
                  at android.content.res.AXmlResourceParser.getName(AXmlResourceParser.java:140)
                  at test.AXMLPrinter.main(AXMLPrinter.java:56)
    So, I think my whole issue is based around these XML files not being converted to human readable before i try and re-package....
    EDIT:::
    Ok, so I found a site that talks about the error I'm getting but it's in chinese, and even after translating the page...I'm still not well versed with terminal and this stuff to get it.
    It reads:
    "Error.
    Final conclusion:
    In minSdkVersion <= 7, AXMLPrinter2.jar can normally decompile xml file
    Greater than 7 can not be normal decompile xml file (AndroidManifest.xml except)
    Give way to share a batch decompile xml file:
    First, create a *. Txt file
    Stresses inside the content authoring
    for / r layout%% a in (*. xml) do @ java-jar AXMLPrinter2.jar "%% a" >> "%% a". txt
    Then this txt file extension into bat form, and this BAT the file and AXMLPrinter2.jar on the same directory will be decompiled xml into the layout directory
    Decompilation results can be generated by executing the bat file multiple xml files."
    - http://hi.baidu.com/ghcghc/item/ecbaa1ce997cb225a0b50ac2
    Maybe someone with more know-how could explain what they're explaining? I get that he's saying the issue im seeing appears when you're using minSdK <=7 but I need to use minSdk 8. Does anyone understand this work around? And how I might go about it on a Mac with terminal?
    I wish adobe would make it easy to remove the "air." from the package name. If they want to convert old Native devs to AIR devs...the transition needs to be seamless. But now I'm about to have to go back to Native because I can't update an app I already have out on the market with an air app.

    Hello~
         I also tried to remove "air." package name in air application. And i encounter the same problem.
         I do not find any solution to decode the xml inside res folder by AXMLPrinter2.jar. And those xml inside is compressed which is unreadable.
         However, what you can do is copying the structure of res folder. And go to your air sdk file path -  adobeair-sdk-folder/lib/android/lib/resources/
         Replace those file exists in your res folder. And copy "values" folder to your res folder.
         Hope this solve your problem~

  • How to change the package name of Managed Bean class

    Hi: Gurus, when ever I create a new JSP page the Creator creates a code behind file with a package name untitled. Is there any way to change this package name? Can't the Creator gives us an option before genereating manged bean page to choose a package name? And then create the Java source directory structure on the basis of the pakcage name?
    Regards,
    Rashid.

    In the Project Navigator (default location is middle right), go to Java Sources, and you can rename the package ("untitled") to something else by right-clicking it or by left-clicking (just like Windows Explorer).
    I agree, though, that giving the developer an option during creation of the JSP page would be nice.

Maybe you are looking for