Need simple example on parsley framework using FLex,Please its urgent

Hi,
     I tried samples on parsley framework using samples like contactmanagement.But i didnt get any output and not able to debug.
Can u pls post any sample on this.

This is an example I put together. It relies soley on the messaging functionality and is designed to be simple. Parsley has many tag (too many) and alternative approaches that you will find variations. However I had a hard time finding some beginner examples clearly explained.
Parsley MVC, RemoteObject, Zend AMF and MySQL Basic Flex Example

Similar Messages

  • Need simple example of flex2 to webservice

    Hello,
    I understand that so long as you don't use remote objects,
    you don't have to buy the FDS! So how do I bypass using FDS and
    just use HTTPS or webservices?
    Can someone point me in the right direction with a
    good/simple example of using flex 2.0 with https and/or
    webservices?
    Thanks,
    K.

    OK - I finally get this.  I guess that SAP Business One is the entry level, least expensive license.  If my company buys SAP Business One, will that provide the R/3 system and BAPIs to build some demos?  And can I hook up SAP Business One to the Sneak Preview SAP NewWeaver 6.40 in order to invoke the BAPIs using Java?
    And I guess that if we buy SAP Busienss One, then I don't need 6.40 ABAP stack to invoke the BAPIS - or do I?
    Thanks for your help.

  • I need simple example for alv grid

    hi
    i need code for simple example for alv grid.
    thanks.

    hi bharat,
                  this is report with most of the functionality.
    report zus_alv_demo_grid .
    tables:     ekko.
    type-pools: slis.
    types: begin of t_ekko,
    ebeln type ekpo-ebeln,
    ebelp type ekpo-ebelp,
    statu type ekpo-statu,
    aedat type ekpo-aedat,
    matnr type ekpo-matnr,
    menge type ekpo-menge,
    meins type ekpo-meins,
    netpr type ekpo-netpr,
    peinh type ekpo-peinh,
    line_color(4) type c, "Used to store row color
    end of t_ekko.
    data: it_ekko type standard table of t_ekko initial size 0,
           wa_ekko type t_ekko.
    *ALV data declarations
    data: fieldcatalog type slis_t_fieldcat_alv with header line,
          gd_tab_group type slis_t_sp_group_alv,
          gd_layout    type slis_layout_alv,
          gd_repid     like sy-repid.
    Data declaration for EVENT and PRINT PARAMETER.
    data: gt_events type slis_t_event,
           gd_prntparams type slis_print_alv.
    data declaration for sorting.
    data : it_sortcat   type slis_sortinfo_alv occurs 1,
           wa_sort like line of it_sortcat.
    data :  i_list_comments type slis_t_listheader.
    start-of-selection.
      perform data_retrieval.
    perform user_command.
      perform build_fieldcatalog.
      perform build_layout.
      perform build_events.
      perform build_print_params.
      perform build_sortcat.
      perform display_alv_report.
    end-of-selection.
    *TOP-OF-PAGE.
    PERFORM top-of-page.
    end-of-page.
    *&      Form  build_fieldcatalog
          text
    -->  p1        text
    <--  p2        text
    form build_fieldcatalog.
      fieldcatalog-fieldname   = 'EBELN'.
      fieldcatalog-seltext_m   = 'Purchase Order'.
      fieldcatalog-col_pos     = 0.
      fieldcatalog-outputlen   = 10.
      fieldcatalog-emphasize   = 'X'.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'EBELP'.
      fieldcatalog-seltext_m   = 'PO Item'.
      fieldcatalog-col_pos     = 1.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'STATU'.
      fieldcatalog-seltext_m   = 'Status'.
      fieldcatalog-col_pos     = 2.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'AEDAT'.
      fieldcatalog-seltext_m   = 'Item change date'.
      fieldcatalog-col_pos     = 3.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MATNR'.
      fieldcatalog-seltext_m   = 'Material Number'.
      fieldcatalog-col_pos     = 4.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MENGE'.
      fieldcatalog-seltext_m   = 'PO quantity'.
      fieldcatalog-col_pos     = 5.
      fieldcatalog-do_sum = 'X'.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MEINS'.
      fieldcatalog-seltext_m   = 'Order Unit'.
      fieldcatalog-col_pos     = 6.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'NETPR'.
      fieldcatalog-seltext_m   = 'Net Price'.
      fieldcatalog-col_pos     = 7.
      fieldcatalog-outputlen   = 15.
      fieldcatalog-datatype     = 'CURR'.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'PEINH'.
      fieldcatalog-seltext_m   = 'Price Unit'.
      fieldcatalog-col_pos     = 8.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
    endform.                    " build_fieldcatalog
    *&      Form  build_layout
          text
    -->  p1        text
    <--  p2        text
    form build_layout.
      gd_layout-no_input          = 'X'.
      gd_layout-colwidth_optimize = 'X'.
      gd_layout-totals_text       = 'Totals'(201).
    Set layout field for row attributes(i.e. color)
      gd_layout-info_fieldname =      'LINE_COLOR'.
    gd_layout-totals_only        = 'X'.
    gd_layout-f2code            = 'DISP'.  "Sets fcode for
    *when double
                                            "click(press f2)*
    gd_layout-group_change_edit = 'X'.
    gd_layout-header_text       = 'helllllo'.
    endform.                    " build_layout
    *&      Form  data_retrieval
          text
    -->  p1        text
    <--  p2        text
    form data_retrieval.
      data: ld_color(1) type c.
      select ebeln ebelp statu aedat matnr menge meins netpr
    peinh from ekpo  into table it_ekko.
    *Populate field with color attributes
      loop at it_ekko into wa_ekko.
    Populate color variable with colour properties
    Char 1 = C (This is a color property)
    Char 2 = 3 (Color codes: 1 - 7)
    Char 3 = Intensified on/off ( 1 or 0 )
    Char 4 = Inverse display on/off ( 1 or 0 )
              i.e. wa_ekko-line_color = 'C410'
        ld_color = ld_color + 1.
    Only 7 colours so need to reset color value
        if ld_color = 8.
          ld_color = 1.
        endif.
        concatenate 'C' ld_color '10' into wa_ekko-line_color.
    wa_ekko-line_color = 'C410'.
        modify it_ekko from wa_ekko.
      endloop.
    endform.                    " data_retrieval
    *&      Form  display_alv_report
          text
    -->  p1        text
    <--  p2        text
    form display_alv_report.
      gd_repid = sy-repid.
      call function 'REUSE_ALV_GRID_DISPLAY'
           exporting
                i_callback_program       = gd_repid
                is_layout                = gd_layout
                i_callback_top_of_page   = 'TOP-OF-PAGE'
                i_callback_user_command  = 'USER_COMMAND'
                i_callback_pf_status_set = 'SET_PF_STATUS'
                it_event                 = gt_events
                is_print                 = gd_prntparams
                it_fieldcat              = fieldcatalog[]
                it_sort                 = it_sortcat
                i_save                   = 'X'
           tables
                t_outtab                 = it_ekko
           exceptions
                program_error            = 1
                others                   = 2.
      if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      endif.
    endform.              " DISPLAY_ALV_REPORT
    *&      Form  user_command
          text
    -->  p1        text
    <--  p2        text
    *&      Form  top-of-page
          text
    -->  p1        text
    <--  p2        text
    form top-of-page.
    *ALV Header declarations
      data: t_header type slis_t_listheader,
            wa_header type slis_listheader,
            t_line like wa_header-info,
            ld_lines type i,
            ld_linesc(10) type c.
    Title
      wa_header-typ  = 'H'.
      wa_header-info = 'EKKO Table Report'.
      append wa_header to t_header.
      clear wa_header.
    Date
      wa_header-typ  = 'S'.
      wa_header-key = 'Date: '.
      concatenate  sy-datum+6(2) '.'
                   sy-datum+4(2) '.'
       sy-datum(4) into wa_header-info."todays date
      append wa_header to t_header.
      clear: wa_header.
    Total No. of Records Selected
      describe table it_ekko lines ld_lines.
      ld_linesc = ld_lines.
      concatenate 'Total No. of Records Selected: ' ld_linesc
         into t_line separated by space.
      wa_header-typ  = 'A'.
      wa_header-info = t_line.
      append wa_header to t_header.
      clear: wa_header, t_line.
      call function 'REUSE_ALV_COMMENTARY_WRITE'
           exporting
           it_list_commentary = t_header
           i_logo             = 'GANESH_LOGO'.
    endform.                    " top-of-page
          FORM user_command                                             *
    -->  R_UCOMM                                                       *
    -->  RS_SELFIELD                                                   *
    form user_command using r_ucomm like sy-ucomm
    rs_selfield type slis_selfield.
      case r_ucomm.
        when '&IC1'.
          if rs_selfield-fieldname = 'EBELN'.
            read table it_ekko into wa_ekko index rs_selfield-tabindex.
            set parameter id 'BES' field wa_ekko-ebeln.
            call transaction 'ME23N' and skip first screen.
          endif.
        when 'ULHAS'.
          if rs_selfield-fieldname = 'EBELN'.
            read table it_ekko into wa_ekko index rs_selfield-tabindex.
            set parameter id 'BES' field wa_ekko-ebeln.
            call transaction 'ME23N' and skip first screen.
          endif.
      endcase.
    endform.
          FORM set_pf_status                                            *
    -->  RT_EXTAB                                                      *
    form set_pf_status using rt_extab type slis_t_extab.
      set pf-status 'ZNEWSTATUS'.
    endform.
    *&      Form  build_events
          text
    -->  p1        text
    <--  p2        text
    form build_events.
      data: ls_event type slis_alv_event.
      call function 'REUSE_ALV_EVENTS_GET'
       exporting
         i_list_type           = 0
       importing
         et_events             = gt_events[]
    EXCEPTIONS
      LIST_TYPE_WRONG       = 1
      OTHERS                = 2
      if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      endif.
      read table gt_events with key name =  slis_ev_end_of_page
                  into ls_event.
      if sy-subrc = 0.
        move 'END_OF_PAGE' to ls_event-form.
        append ls_event to gt_events.
      endif.
      read table gt_events with key name =  slis_ev_end_of_list
                  into ls_event.
      if sy-subrc = 0.
        move 'END_OF_LIST' to ls_event-form.
        append ls_event to gt_events.
      endif.
    endform.                    " build_events
    *&      Form  build_print_params
          text
    -->  p1        text
    <--  p2        text
    form build_print_params.
      gd_prntparams-reserve_lines = '3'.   "Lines reserved for footer
      gd_prntparams-no_coverpage = 'X'.
    endform.                    " build_print_params
          FORM END_OF_PAGE                                              *
    form end_of_page.
      data: listwidth type i,
      ld_pagepos(10) type c,
      ld_page(10)    type c.
      write: sy-uline(50).
      skip.  write:/40 'Page:', sy-pagno .
    endform.
          FORM END_OF_LIST                                              *
    form end_of_list.
      data: listwidth type i,
      ld_pagepos(10) type c,
      ld_page(10)    type c.
      skip.  write:/40 'Page:', sy-pagno .
    endform.
    *&      Form  build_sortcat
          text
    -->  p1        text
    <--  p2        text
    form build_sortcat.
    wa_sort-spos      = 1.
    wa_sort-fieldname = 'EBELN'.
    append wa_sort to it_sortcat.
    wa_sort-spos      = 2.
    wa_sort-fieldname = 'EBELP'.
    append wa_sort to it_sortcat.
    endform.                    " build_sortcat
    Rewards if helpfull
    regards
    vijay dwivedi

  • Need Simple Example of Notifier and Occurance

    hi friends
    i need to know the exact funtion of notifiers and occurances. So can you send me the simple example for both..
    Thanks in advance... 

    Open your example finder (help..find examples...") and search for these two terms.
    I recommend looking at "General Notifier example.vi" and "Generate Occurrences.vi".
    Is there anything in the online help that is not clear? What are you trying to do?
    Message Edited by altenbach on 09-26-2008 11:22 PM
    LabVIEW Champion . Do more with less code and in less time .

  • Help, need simple instructions on how to use numbers with keyboard.

    I just got Numbers for IPAD 2 and I am new to Spreadsheets in general.  I simply cannot understand how to use this program with my mini external keyboard (gotten from Apple)  to make it do what I need it to do.  I am trying to set up a spreadsheet for my Jewelry Design Business.  It's an inventory Spreadsheet, listing each item, the number of the item, the title, description, price and final sold price and type of Jewelry.  I need the two price columns to add the sum of all the jewelry in each row, which by some miracle I was actually able to do.  What I am having trouble with is getting it to automatically change to dollars for the two price columns without having to touch the dollar sign on the formula bar each time I enter a new item, and getting it to jump from the last cell in the last column to the first cell of the first column when I am finished with a row and need to go to the next item.  What it does do is either jump to the cell right beneath it, or go backwards, or sometimes it does go to the first cell of the next line, but I don't know what I am doing to make that happen.  Anyway being new to this all, it is obvious I need specific simple instructins on how to use this program. Does anybody know where I can find some help?

    IMHO, forget about doing any meaningful Excel work an iPad unless you want to be a slave and spend 3-4 times the amount of time it would take to do inputs on a normal computer.  Now, IF there was mouse support, then it might be worth the effort.  I tried it and gave up.

  • Need an Example for Enterprise Services using PI

    Hi
      I have been trying to configure and execute the demo - Cancel Flight Booking, but have been facing some issues on the configuration front. So if any of you had done any simpler examples, i would like to go through them. I'm very new to SAP and I want to learn about looking up,invoking enterprise services using PI. So kindly help with providing any custom made simple example with the configuration steps.
    Thanks & Regards
    Vijay

    Hi,
    habve you see this demo:
    /people/jitender.chauhan/blog/2009/04/20/service-enabling-in-abap
    Regards,
    Michal Krawczyk

  • New developer with spacial - need simple example

    Dear All
    i developing an application that need to store coordinates which represented with 3 floats. i need simple demo which illustrates me how can i insert such coordinate using Oracle Spatial and the how to select it. i also need little explanation of the structure of the select and insert queries
    Thanks alot

    Well, Ron, I think you will need to read a minimum in order to use oracle spatial. I admit that the Oracle docset can seem daunting, but I don't think you can use it without at least reading some of the Oracle Spatial Users Guide, available here (file://localhost/D:/Doc/Oracle/1020/B19306_01/appdev.102/b14255/toc.htm) in HTML and PDF.
    I suggest reading at least chapters 1 (concepts) and 2 (data types) in this manual.
    Albert

  • I want to make an identity card of my dad. he is a government employee. so can you send me whole method to make it using Photoshop CS2 ? please its urgent,

    i want to make an identity card of my dad. he is a government employee. so can you send me whole method to make it using Photoshop CS2 ? please its urgent

    Identity cards are not things individuals typically make.
    You can get yourself into big trouble forging fake IDs.
    -Noel

  • Need a simple example program code to use SF_EXAMPLE_01

    Hi all,
    I have just try to learn smartforms. As i have SAP NW4 for learning.
    I found SF_EXAMPLE_01 in the system.
    Can any body help me out how to use this example in abap program code?
    Thanks.
    rob

    Smart Forms, try this steps.. it will teach you how to create smart form and how to use it.
    1) Tcode --> SmartForms
    2) Form name --> Z_SF_TEST Create
    3) Under Global settings
    a) Form Interface  
        Table Tab
       ITAB LIKE EKPO
    b) GLOBAL Definitions
    WA_NETPR LIKE EKPO-NETPR
    In smart forms if we want to display quantity and currency fields. We can't directly display currency field and quantity fields
    For that we have to create an extra variable in global definitions
    Ex: netpr FIELD of EKPO
    CREATE program lines and specify WA_NETWR = itab-netpr.
    4) RT CLick on main Window
       CREATE --> TABLE
      Click Table painter
    DEFAULT %LTYPE will be Created
    a) If you want more like Header footer etc add by rt click on %LTYPE1
    Table (Tab)
    %LTYPE  Radio(SELECT) 5 CM 5 CM 6 CM
    CLICK on DATA (Tab)
    INTERNAL TABLE ITAB LIKE ITAB
    5)RT click on table control and create --> program lines
    General attribute (Tab)
    INPUT PARAMETER               OUTPUT PARAMETER
    itab                               WA_NETPR
    Code Area
    WA_NETWR = ITAB-NETPR.
    6) RT CLcick on table ctl and create 3 text to display the fields
    a) % text1 +button(insert field)
       FIELD name &itab-ebeln&
    Output options (tab)
    Check New line   LINETYPE   %Ltype1
    check new cell
    b) % text2
       & itab-ebelp&
    output options
    check new cell
    c) % text2
       & wa_netpr&
    output options
    check new cell
    Report ac
    Tables ekpo.
    Data: itab1 like ekpo occurs 0 with header line.
    select * into table itab1 from ekpo.
    Call function module   "to know function module name goto smartform and execute the smart form name it will give you the function module name.
    If your question is answered, close the thread and reward all useful answers...
    Regards,
    Sairam

  • Need an example of how to use java.nio.channels.FileLock

    Hi,
    I need to use the Filelock, but can�t find any examples on how to implement it -
    is it still used in Java 5.0?

    Would this be the correct way to check whether the file is already locked?
    public static void main(String[] args) throws Exception {
         FileOutputStream fos = new FileOutputStream("data.txt");
         FileLock fl = fos.getChannel().tryLock();
         if (fl != null) {
         System.out.println("Locked File");
         Thread.sleep(30000);
         fl.release();
         System.out.println("Released Lock");
         else{
              System.out.println("File is already locked!");
         fos.close();
         }

  • Need simple example on Soap With attachment webservice

    Hi
    I want to explore following points:-
    1. How to create a webservice that accept attachment.
    2. java Client to send the attachment to webservice
    3. using OSB to send attachment to webservice?
    Does any have any example tht will help to understand this, Please post the link will be great help?
    Thanks

    There is one sample in jeffdavies.org site. Download the code samples and check if it helps you.

  • Need to update list page using a pop up dialog page (Please its URGENT)

    Hi,
    I have master page with list of employees. Using a pop up dialog I'am trying to insert a new record but the record is not appearing in the list.
    Possible solutions tried but no hope:
    1. Using managed bean I tried with refreshing (re-execute) the iterator and binding container of employee list page.
    2. Used a navigation from popup dialog to list page along with returnActionListener associated on button.
    Thanks in advance,
    Syed Fazal

    Hi Syed,
    you may try in your return event
    FacesContext context = FacesContext.getCurrentInstance();
    NavigationHandler nh = context.getApplication().getNavigationHandler();
    nh.handleNavigation(context, null, "whateveryournavigationruleis");

  • Generate a restaurant bill using bluej. plz its urgent

    To generate a restaurant bill using blue j. take 3 categories of items like punjabi chinese and continental. take 3 dishes for each category.enter the quantity needed and display the total.

    Please drop the usage of shorthand for words, the use
    "u" and "plz" will only irritate peopleMe too. I can no longer read SMS messages from my sister....
    I assume you know a bit about OOP (object oriented programing). Think about a receipt, what do you have??
    1. The receipt.
    2. (which contains) items.
    What properties do each of these (objects) have? Well.... an item has a cost? A receipt has items. (You want to be able to add items to the receipt and maybe remove the last item added and calculate the total of all the items maybe). Carry on thinking, what else have you got. You should now be able to develop skeleton objects.
    And for reference, your post is not urgent. Although you have given a slightly better subject than help. (I know nothing about blueJ)

  • R12 upgrade issue:Not able to login using forms:Please help****urgent

    We have recently upgraded our instance from 11.5.9 to 12.0.4 in Windows 2003 server.
    We are unable to login to forms after upgrade, however we are able access self service responsibilities without any issues.
    We are getting APP-FND-01496 when we access any forms responsibility. We have tried all possible metalink notes with no luck.
    Any help to resolve this issue will be appreciated.

    Duplicate thread ...
    R12 upgrade issue:Not able to login to forms**please help
    Re: R12 upgrade issue:Not able to login to forms**please help

  • How to generate key pair using java ?(its urgent)

    We r working on java card. For security purpose I want a Key pair.
    If anyone is able to uide me by giving me a small code or algorithm i am very thankful.
    Its an urgent !!!!
    Plz inform me if any relative information u r having.

    import java.security.KeyPairGenerator;
    import java.security.KeyPair;
    import java.security.PrivateKey;
    import java.security.PublicKey;
    import java.security.SecureRandom;
    import java.security.KeyFactory;
    import java.security.spec.PKCS8EncodedKeySpec;
    import java.security.spec.X509EncodedKeySpec;
    import java.io.FileOutputStream;
    import java.io.FileInputStream;
    public class ParClaves {
         public KeyPairGenerator keyPairGenerator;
         public KeyPair keyPair;
         public PrivateKey privateKey;
         public PublicKey publicKey;
         public String algoritmo = "DSA"; // DSA o RSA
         public String proveedor = null;
         public int keysize = 1024;
         public SecureRandom random = null;
         public void guardarClaves(String fichClavePublica, String fichClavePrivada) throws Exception {
              byte[] key = this.publicKey.getEncoded();
              FileOutputStream keyfos = new FileOutputStream(fichClavePublica);
              keyfos.write(key);
              keyfos.close();               
              key = this.privateKey.getEncoded();
              keyfos = new FileOutputStream(fichClavePrivada);
              keyfos.write(key);
              keyfos.close();               
         } // fin de guardarClaves
         public void guardarClaves(String fichClavePublica, String fichClavePrivada, KeyPair keyPair) throws Exception {
              byte[] key = keyPair.getPublic().getEncoded();
              FileOutputStream keyfos = new FileOutputStream(fichClavePublica);
              keyfos.write(key);
              keyfos.close();               
              key = keyPair.getPrivate().getEncoded();
              keyfos = new FileOutputStream(fichClavePrivada);
              keyfos.write(key);
              keyfos.close();               
         } // fin de guardarClaves     
         public KeyPair recuperarClaves(String fichClavePublica, String fichClavePrivada) throws Exception {
              return new KeyPair(recuperarClavePublica(fichClavePublica), recuperarClavePrivada(fichClavePrivada));
         } // fin de recuperarClaves
         public PublicKey recuperarClavePublica(String fichClavePublica) throws Exception {
    // PENDIENTE: seguramente, para que esto fuera v�lido, habr�a que proporcionar el Proveedor ?�
    // probar generando clavePublica con otro proveedor distinto de SUN
              FileInputStream fis = new FileInputStream(fichClavePublica);
              byte[] encKey = new byte[fis.available()];
              fis.read(encKey);
              fis.close();
              KeyFactory keyFactory = null;
              try {
                   keyFactory = KeyFactory.getInstance("DSA");
              } catch (Exception e) {
                   keyFactory = KeyFactory.getInstance("RSA");
              } // fin del try
              X509EncodedKeySpec pubKeySpecX509 = new X509EncodedKeySpec(encKey);
              PublicKey publicKey = keyFactory.generatePublic(pubKeySpecX509);
              return publicKey;
         } // fin de recuperarClavePublica
         public PrivateKey recuperarClavePrivada(String fichClavePrivada) throws Exception {
    // PENDIENTE: seguramente, para que esto fuera v�lido, habr�a que proporcionar el Proveedor ?�
    // probar generando clavePrivada con otro proveedor distinto de SUN
              FileInputStream fis = new FileInputStream(fichClavePrivada);
              byte[] encKey = new byte[fis.available()];
              fis.read(encKey);
              fis.close();
              KeyFactory keyFactory = null;
              try {
                   keyFactory = KeyFactory.getInstance("DSA");
              } catch (Exception e) {
                   keyFactory = KeyFactory.getInstance("RSA");
              } // fin del try
              PKCS8EncodedKeySpec privKeySpecPKCS8 = new PKCS8EncodedKeySpec(encKey);
              PrivateKey privateKey = keyFactory.generatePrivate(privKeySpecPKCS8);
              return privateKey;
         } // fin de recuperarClavePrivada
         public KeyPair generarClaves() throws Exception {
              if (this.proveedor == null) {
                   this.keyPairGenerator = KeyPairGenerator.getInstance(this.algoritmo);
                   this.proveedor = this.keyPairGenerator.getProvider().getName();
              } else {
                   this.keyPairGenerator = KeyPairGenerator.getInstance(this.algoritmo, this.proveedor);
              } // fin del if
              if (this.random == null) {
                   this.keyPairGenerator.initialize(this.keysize);
              } else {
                   this.keyPairGenerator.initialize(this.keysize, this.random);
              } // fin del if
              this.keyPair = this.keyPairGenerator.generateKeyPair();
              this.privateKey = this.keyPair.getPrivate();
              this.publicKey = this.keyPair.getPublic();
              return this.keyPair;
         } // fin de generarClaves
         public KeyPair generarClaves(SecureRandom random) throws Exception {
              this.random = random;
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(int keysize) throws Exception {
              this.keysize = keysize;
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(int keysize, SecureRandom random) throws Exception {
              this.keysize = keysize;
              this.random = random;          
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmoOproveedor) throws Exception {
              decidir(algoritmoOproveedor);
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmoOproveedor, SecureRandom random) throws Exception {
              decidir(algoritmoOproveedor);
              this.random = random;          
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmoOproveedor, int keysize) throws Exception {
              decidir(algoritmoOproveedor);
              this.keysize = keysize;          
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmoOproveedor, int keysize, SecureRandom random) throws Exception {
              decidir(algoritmoOproveedor);
              this.keysize = keysize;          
              this.random = random;                    
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmo, String proveedor) throws Exception {
              this.algoritmo = algoritmo;          
              this.proveedor = proveedor;                    
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmo, String proveedor, SecureRandom random) throws Exception {
              this.algoritmo = algoritmo;          
              this.proveedor = proveedor;
              this.random = random;                              
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmo, String proveedor, int keysize) throws Exception {
              this.algoritmo = algoritmo;          
              this.proveedor = proveedor;
              this.keysize = keysize;                              
              return generarClaves();
         } // fin de generarClaves
         public KeyPair generarClaves(String algoritmo, String proveedor, int keysize, SecureRandom random) throws Exception {
              this.algoritmo = algoritmo;          
              this.proveedor = proveedor;
              this.keysize = keysize;
              this.random = random;          
              return generarClaves();
         } // fin de generarClaves
         public String getInformacion() {
              StringBuffer sb = new StringBuffer();
              sb.append("Algoritmo: " + this.algoritmo + "\n");
              sb.append("Proveedor: " + this.proveedor + "\n");
              sb.append("Keysize: " + this.keysize + "\n");
              return sb.toString();
         } // fin de getInformacion
         public boolean esAlgoritmoValido(String algoritmo) {
              try {
                   KeyPairGenerator keyPairGenerator = KeyPairGenerator.getInstance(algoritmo);
                   return true;
              } catch (Exception e) {
                   return false;
              } // fin del try
         } // fin de esAlgoritmoValido
         private void decidir(String algoritmoOproveedor) {
              if (esAlgoritmoValido(algoritmoOproveedor)) {
                   this.algoritmo = algoritmoOproveedor;
              } else {
                   this.proveedor = algoritmoOproveedor;
              } // fin del if
         } // fin de decidir
    } // fin de ParClaves

Maybe you are looking for

  • Create PO with the check box of free item selected automaticly

    Hi all, We would like to create PO's with a normal position and a second position which is free. Is there a possibility to have a special position type for free goods? We don't want to check this checkbox every time we create a PO... Thanks, Thomas

  • Unable to capture video from webcam in JMF

    hi I am unable to capture video from webcam in an Xlet. I am using Xletview to run Xlet. The method CaptureDeviceManager.getDeviceList(vidformat) returns empty array. Which videoformat should I use and why do I get empty array?

  • My ipod shuffle 4th doesn't connect to itunes or windows, what can I do?

    hello, it's been like 2 weeks since I did the update of itunes and everything to get my ipod shuffle 4th generation, and also did all the troubleshooting from the apple page, and nothing happens. It doesn't connect to itunes or windows. anyone of you

  • Getting Blank Screen

    Hi Experts, We has a custom java application which was deployed on Weblogic 8 in 2 JVM Cluster. Recently we have upgraded the Weblogic to version 10MP3. But sometime users are getting blank screens and once they hit F5 the screen comes back. Users ar

  • Apeture for RAW photos on Macbook Pro retina?

    My Macbook Pro 15" 2011 was stolen and I planned to replace it with the MacBook Pro 13" retina simply because liked the smaller size - but then discovered that the graphics card was not the same.  I edit my RAW photos on Aperture.  Will I be doing th