Need help on -- Size of object

how do i get the size of the object ?
Thanks in Advance

You can't. What makes you think you need this, because in Java we don't need to worry about this. You do not explicitly allocate or free memory, so the size of an object is not needed. Some people will tell you to serialize an object to a byte array and that the size of the array is the size of the object, but they're completely wrong. The size of an object is, roughly, the size of every primitive field it has, plus the size of a reference to an object multiplied by the number of reference fields, plus a small overhead for simply existing itself. But as I said, you don't need to worry about it

Similar Messages

  • Urgent. Need help in the Calendar Object.

    Hello developers, best regards!
    Well my problem is that i'm facing a fact that i need a calendar object just like that one when u click the time down there in the taskbar, i need to embedd it in my java windows application.
    To be more clear, if u're familiar with the Visual Basic.NET environment, just the kind of calendars that i need is found there, in which it displays a small box which i can select the months, and accordingly i can select the specific date i need.
    Please i need your help so much.
    Thank you in advance.

    [url http://www.google.co.uk/search?hl=en&q=jcalendar&meta=]click

  • Need help changing size and aspect ratio for 500+ images

    Thank you for reading this! I have about 500 images of people in different poses. They're all extracted on a transparency as PNGs. They vary in aspect ratio, dimensions and position of the person within the frame - for some the feet are very close to the bottom of the frame and for some, they're higher up. I need to equalize all 3 of these qualities, so that if superimposed, they look like a video unfolding with the same zoom. My ideal size would be 800x800 at 300ppi.
    Is there a way to batch even a part of the process and keep the png format? I had the images in PSD initially but they were too massive so creating catalogs with them was prohibitive.
    If not possible to do a batch, what would be the best (easiest) and fastest way to do it? I'm thinking that maybe creating some template where an oval shape the size of the head can help create consistency of the size of the person and a line that helps set up the distance from the bottom?
    I so appreciate any help you have to offer. Part of my problem is that I don't know what these processes are called so I don't even know what to search for. If you can even name the actions that I need, it would be of great help. I already paid a designer to do the extraction and they were supposed to do this formatting as well and they didn't so my budget is shot. I'm hoping that if I understand what the steps are, I can do them myself.
    Thank you!

    If you download my crafting actions package you can record an action that uses one of my plug-in scripts to do that process. You could then batch that action and process your 500 png image files.
    Crafting Actions Package UPDATED Aug 10, 2014 Added Conditional Action steps to Action Palette Tips.
    Contains
    Action Actions Palette Tips.txt
    Action Creation Guidelines.txt
    Action Dealing with Image Size.txt
    Action Enhanced via Scripted Photoshop Functions.txt
    CraftedActions.atn Sample Action set includes an example Watermarking action
    Sample Actions.txt Photoshop CraftedActions set saved as a text file.
    More then a dozen Scripts for use in actions
    Example
    Download
    Step 1 Select layers transparency
    Step 2 Copy
    Step 3 Paste
    Step 4 Select all
    Step 5 Align Layer s to selection vertical center
    Step 6 Align Layer s to selection horizontal center
    Step 7 Select bottom Layer
    Step 8 delete current layer
    Ste9 9 Fille>Automate>AspectRatopSelection... In the dialog set 1 1 ratio center rectangle replace selection feather 0
    Step 10 Image Crop
    Step 11 File Automate>Fit Image.  In dialog enter width and height 800
    Step 12 Image size in the dialog uncheck Resample and enter 300 in the resolution field.
    I'm sure the should work you mane not need the copy paste and it depends on how Photoshop treats the PNG layer the canvas size or just the pixels.
    This may also work
    Step 1 Select all
    Step 2 Align Layer s to selection vertical center
    Step 3 Align Layer s to selection horizontal center
    Ste9 4 Fille>Automate>AspectRatopSelection... In the dialog set 1 1 ratio center rectangle replace selection feather 0
    Step 5 Image Crop
    Step 6 File Automate>Fit Image.  In dialog enter width and height 800
    Step 7 Image size in the dialog uncheck Resample and enter 300 in the resolution field.

  • Need help w/ making an object appear WHEN a button is pressed

    I've tried to figure this out on my own, but am stumped. I even tried using the .setVisible command... but that didnt work. What I would like to happen is to just have the stick figure appear, sans clothing. Then when the "Add Shirt" button is pressed I want the stick figure to acquire a shirt. Same goes for pants.
    import java.awt.event.*;
    import java.awt.*;
    import java.applet.*;
    public class dolls extends Applet implements AdjustmentListener, ActionListener {
         Shirt myShirt;
         Pants myPants;
         Color c;
         Scrollbar red,green,blue;
         int redValue, greenValue, blueValue, clothing = 0;
         Label redColor, greenColor, blueColor;
         Button shirt, pants;
         boolean clickedShirt = false, clickedPants = false;
         public void init(){
              redColor = new Label("Red");
              add(redColor);
              red = new Scrollbar(Scrollbar.HORIZONTAL,0,0,0,256);
              add(red);
              red.addAdjustmentListener(this);
              greenColor = new Label("Green");
              add(greenColor);
              green = new Scrollbar(Scrollbar.HORIZONTAL,0,0,0,256);
              add(green);
              green.addAdjustmentListener(this);
              blueColor = new Label("Blue");
              add(blueColor);
              blue = new Scrollbar(Scrollbar.HORIZONTAL,0,0,0,256);
              add(blue);
              blue.addAdjustmentListener(this);
              shirt = new Button("Add Shirt");
              add(shirt);
              pants = new Button("Add Pants");
              add(pants);
              myShirt = new Shirt(120,125,3);
              myPants = new Pants(120,125,3);
         public void adjustmentValueChanged(AdjustmentEvent e){
              redValue = red.getValue();
              greenValue = green.getValue();
              blueValue = blue.getValue();
              repaint();
         public void paint(Graphics g){
              g.drawOval(150,100,30,30);
              g.drawLine(165,130,165,180);
              g.drawLine(165,133,120,160);
              g.drawLine(165,133,210,160);
              g.drawLine(165,180,143,235);
              g.drawLine(165,180,187,235);
              if(clickedShirt = true) {
                   c = new Color(redValue, greenValue, blueValue);
                   g.setColor(c);
                   myShirt.display(g);
              if(clickedPants = true){
                   clickedPants = true;
                   c = new Color(redValue, greenValue, blueValue);
                   g.setColor(c);
                   myPants.display(g);
         public void actionPerformed(ActionEvent ae){
              if(ae.getSource() == shirt)
                   clickedShirt = true;
                   repaint();
              if(ae.getSource() == pants)
                   clickedPants = true;
    // <applet code = "dolls.class" height = 300 width=350> </applet>If needed I will post the code for the shirt and pants classes.
    Thank you all for your help.

    code for pants.class
    import java.awt.*;
    public class Pants {
         Polygon pants;
         public Pants(int h, int v, int size){
              pants = new Polygon();
              pants.addPoint(10*size+h,18*size+v); // 1
              pants.addPoint(20*size+h,18*size+v); // 2
              pants.addPoint(25*size+h,35*size+v); // 3
              pants.addPoint(18*size+h,35*size+v); // 4
              pants.addPoint(15*size+h,27*size+v); // 5
              pants.addPoint(13*size+h,35*size+v); // 6
              pants.addPoint(05*size+h,35*size+v); // 7
         public void display(Graphics g){
              g.fillPolygon(pants);
    }code for shirts.class
    import java.awt.*;
    public class Shirt {
         Polygon shirts;
         int h;
         public Shirt(int h, int v, int size){
              shirts = new Polygon();
              shirts.addPoint(12*size+h,1*size+v); // 1
              shirts.addPoint(18*size+h,1*size+v); // 2
              shirts.addPoint(29*size+h,9*size+v); // 3
              shirts.addPoint(26*size+h,12*size+v); // 4
              shirts.addPoint(20*size+h,8*size+v); // 5
              shirts.addPoint(20*size+h,20*size+v); // 6
              shirts.addPoint(10*size+h,20*size+v); // 7
              shirts.addPoint(10*size+h,8*size+v); // 8
              shirts.addPoint(4*size+h,12*size+v); // 9
              shirts.addPoint(1*size+h,9*size+v); //10
         public void display(Graphics g){
              g.fillPolygon(shirts);
         public void changeH(int changeHpos){
              h = h + changeHpos;
    }

  • Need help in SAP Business Object Dashboard

    Hey, I need some help.
    i have a dashboard which is current built in Qlikview.
    Now our client proposed that they need to migrate this dashboard to SAP Business Object.
    Please guide about dashboard desigining using SAP, since i am absolute novice about BO so guide according like which BO software needs to be install and some learning material of BO, please email @ [email protected]
    Many Many Thanks in advance!!

    Too generic to answer this question and also you can find lot of thread, discussions & blogs are available to get the info. Also you can find some templates & samples inside the dashboard itself, play with those component and understand them better.
    Best place to get familiar with the dashboard using the tutorials.
    Official Product Tutorials – SAP BusinessObjects Dashboards
    Installing SAP BusinessObjects Dashboards 4.0
    http://help.sap.com/businessobject/product_guides/boexir4/en/xi4_dashD_user_en.pdf
    SAP BusinessObjects Dashboards 4.0, SAP Crystal Dashboard Design 2011, SAP Crystal Presentation Design 2011 - Product Av…
    SAP BusinessObjects Dashboards 4.1 – SAP Help Portal Page
    SAP BusinessObjects Dashboards Resource Centre
    Please go through the above links which can help you to understand how dashboard works, install & Product availability matrix.

  • Need help!  Simple session object problem.

    Help! I've been working on this for 4 days, but I'm sure it's simple if you are experienced. I'm receiving an error when I try to create the session variable (line 29)
    I just want to
    A) take the record ID's from a string variable on a sort page,
    B) create a string session variable which has those ID's
    C) and then pass it to the cart page, where the ID's will be used to display multiple records.
    1) (From the sort page), using an ADD TO CART BUTTON, Pass the record ID's in the String chkValues[] to a session variable.
    2)Figure out how to be able to access that session variable from the cart page: (The issue is that the form on the sort page already uses a GET method to perform the sort.)
    ERROR
    500 Internal Server Error - /jserv/Detail2.jsp:
    Compilation error occured:
    Found 2 errors in JSP file:
    C:\\Inetpub\\wwwroot\\Beachwear\\jserv\\Detail2.jsp:27: Syntax: Expression expected after this token
    <%@page language="java" import="java.sql.*"%>
    <%@ include file="../Connections/connBeachwear.jsp" %>
    <%@page language="java" import="java.sql.*,java.util.*"%><%//ADDED 12/14 %>
    <%
    //INCLUDE CHECKED ITEMS IN SORT:
    String rsBeachwear__varCheckbox = "1";
    if (request.getParameter ("valueCheckbox") !=null) {rsBeachwear__varCheckbox = (String)request.getParameter ("valueCheckbox")   ;}
    %>
    <%
    String rsBeachwear__name = "ID";//default sort value
         if (request.getParameter ("order") !=null) {rsBeachwear__name = (String)request.getParameter ("order");}
    String rsBeachwear__sort = "ASC";//default sort value
         if (request.getParameter ("sort") !=null) {rsBeachwear__sort = (String)request.getParameter ("sort");}
    String rsBeachwear__orderby ="ID";//default value
         if (request.getParameter ("order") !=null) {rsBeachwear__orderby = (String)request.getParameter("order");}
    String rsBeachwear__sortby ="ASC";//default value
         if (request.getParameter ("sort") !=null) {rsBeachwear__sortby = (String)request.getParameter("sort");}
    %>
    <%
    Driver DriverrsBeachwear = (Driver)Class.forName(MM_connBeachwear_DRIVER).newInstance();
    Connection ConnrsBeachwear = DriverManager.getConnection(MM_connBeachwear_STRING,MM_connBeachwear_USERNAME,MM_connBeachwear_PASSWORD);
    String chkValues[]=request.getParameterValues("valueCheckbox");
    session.setAttribute("chkValues2",chkValues[]);          //AND NOW MAY BE ADDED TO CART
    StringBuffer prepStr=new StringBuffer("SELECT ID, Item, Color, Size FROM Beachwear WHERE ID=");
    for(int x = 0; x < chkValues.length; ++x) {
         prepStr.append(chkValues[x]);
         if((x+1)<chkValues.length){
              prepStr.append(" OR ID=");
              }//end if
         }//end for loop
         prepStr.append(" ORDER BY " + rsBeachwear__name + " " + rsBeachwear__sort ); //NEW SQL SORT CODE:
    PreparedStatement StatementrsBeachwear=ConnrsBeachwear.prepareStatement(prepStr.toString());
    ResultSet rsBeachwear = StatementrsBeachwear.executeQuery();
    Object rsBeachwear_data;
    %>
    <title>Beachwear Title</title>
    <body bgcolor="#FFFFFF">
    <p align="center"><b><font size="4">DETAIL PAGE</font></b></p>
    <form name="form1" method="get" action="Detail2.jsp">
    <table width="75%" border="1">
    <tr>
    <td width="20%">
    <div align="center">Sort Parameter </div>
    </td>
    <td width="19%">
    <div align="center">Sort 1</div>
    </td>
    <td width="25%">
    <div align="center">Sort 2</div>
    </td>
    <td width="36%">
    <div align="center">Add Records to Cart:</div>
    </td>
    <td width="36%">
    <div align="center">
    <div align="center">Go to Cart</div>
    </div>
    </td>
    </tr>
    <tr>
    <td width="20%">
    <div align="center">
    <input type="submit" value="Sort /Select" name="submit">
    </div>
    </td>
    <td width="19%">
    <div align="center">
    <select name="order" size="1">
    <option value="ID" <% if (rsBeachwear__orderby.equals("ID")) {out.print("selected"); } %> >ID</option>
    <option value="Item" <% if (rsBeachwear__orderby.equals("Item")) {out.print("selected"); } %> >Item</option>
    <option value="Color" <% if (rsBeachwear__orderby.equals("Color")) {out.print("selected"); } %> >Color</option>
    <option value="Size" <% if (rsBeachwear__orderby.equals("Size")) {out.print("selected"); } %> >Size</option>
    </select>
    </div>
    </td>
    <td width="25%">
    <div align="center">
    <select name="sort" size="1">
    <option value="ASC" <% if (rsBeachwear__sortby.equals("ASC")) {out.print("selected"); } %>>Ascending</option>
    <option value="DESC" <% if (rsBeachwear__sortby.equals("DESC")) {out.print("selected"); } %>>Descending</option>
    </select>
    </div>
    </td>
    <td width="36%">
    <div align="center">
    <input type="submit" name="Submit" value="Add to Cart">
    </div>
    </td>
    <td width="36%">
    <div align="center">
    <div align="center">
    <input type="button" name="butGoToCart" value="Go to Cart" onClick="window.location='../jserv/Cart2.jsp'">
    </div>
    </div>
    </td>
    </tr>
    </table>
    <p>�</p>
    <%while(rsBeachwear.next()){%>
    <table width="75%" border="1">
    <tr>
    <td width="17%">ID:</td>
    <td width="58%"><%=(((rsBeachwear_data = rsBeachwear.getObject("ID"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    <td width="25%">
    <div align="center">Include in Sort:
    <input type="checkbox" name="valueCheckbox" value="<%=(((rsBeachwear_data = rsBeachwear.getObject("ID"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%>" checked>
    </div>
    </td>
    </tr>
    <tr>
    <td width="17%">ITEM:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Item"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%">COLOR:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Color"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%">SIZE:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Size"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%" bgcolor="#00FFFF" bordercolor="#FFFFFF">
    <div align="left"></div>
    </td>
    <td colspan="3" bgcolor="#00FFFF" bordercolor="#FFFFFF">� </td>
    </tr>
    </table>
    <%
    %>
    <p>�</p>
    </form>
    <%
    rsBeachwear.close();
    ConnrsBeachwear.close();
    %>

    Thanks so much for your informative response!
    I would value your advice and direction to correct the structure of the code, but I am a very methodical person and first must complete the prototype in JSP before I go on to the next step of applying the MVC structure to correct the inefficiencies. (Also, it will be invaluable to the learning process be able to compare the two.) Just as in learning Math, you must learn the long way of problem solving before you apply the sophisticated, less error prone, and more structured approach.
    I have a sort that works pefectly, and displays only the records that have "checks" in the checkboxes. By unchecking the checkbox for individual records, (and then pressing the Sort/Select button), the sort is re-run using only the ID's of records that have been "checked."
    When ADD TO CART is pressed, I want to pass the ID's from the displayed records to a persistent session variable. And then when "DISPLAY CART" is pressed, I want to view a sort page EXACTLY like the original sort page, except the variable holding the diplayed records IS the persistent session variable. I'm not sure how to add only unique ID's to the session variable?
    I'd appreciate any assistance to complete this step, so I can go on and develop the MVC structure.
    Thank you again.
    <%@page language="java" import="java.sql.*"%>
    <%@ include file="../Connections/connBeachwear.jsp" %>
    <%@page language="java" import="java.sql.*,java.util.*"%><%//ADDED 12/14 %>
    <%
    //INCLUDE CHECKED ITEMS IN SORT:
    String rsBeachwear__varCheckbox = "1";
    if (request.getParameter ("valueCheckbox") !=null) {rsBeachwear__varCheckbox = (String)request.getParameter ("valueCheckbox")   ;}
    %>
    <%
    String rsBeachwear__name = "ID";//default sort value
    if (request.getParameter ("order") !=null) {rsBeachwear__name = (String)request.getParameter ("order");}
    String rsBeachwear__sort = "ASC";//default sort value
    if (request.getParameter ("sort") !=null) {rsBeachwear__sort = (String)request.getParameter ("sort");}
    String rsBeachwear__orderby ="ID";//default value
    if (request.getParameter ("order") !=null) {rsBeachwear__orderby = (String)request.getParameter("order");}
    String rsBeachwear__sortby ="ASC";//default value
    if (request.getParameter ("sort") !=null) {rsBeachwear__sortby = (String)request.getParameter("sort");}
    %>
    <%
    Driver DriverrsBeachwear = (Driver)Class.forName(MM_connBeachwear_DRIVER).newInstance();
    Connection ConnrsBeachwear = DriverManager.getConnection(MM_connBeachwear_STRING,MM_connBeachwear_USERNAME,MM_connBeachwear_PASSWORD);
    String chkValues[]=request.getParameterValues("valueCheckbox");
    session.setAttribute("chkValues2",chkValues); //IS THIS THE CORRECT WAY TO ADD ID'S TO A SESSION VARIABLE?
    StringBuffer prepStr=new StringBuffer("SELECT ID, Item, Color, Size FROM Beachwear WHERE ID=");
    for(int x = 0; x < chkValues.length; ++x) {
    prepStr.append(chkValues[x]);
    if((x+1)<chkValues.length){
    prepStr.append(" OR ID=");
    }//end if
    }//end for loop
    prepStr.append(" ORDER BY " + rsBeachwear__name + " " + rsBeachwear__sort ); //NEW SQL SORT CODE:
    PreparedStatement StatementrsBeachwear=ConnrsBeachwear.prepareStatement(prepStr.toString());
    ResultSet rsBeachwear = StatementrsBeachwear.executeQuery();
    Object rsBeachwear_data;
    %>
    <title>Beachwear Title</title>
    <body bgcolor="#FFFFFF">
    <p align="center"><b><font size="4">DETAIL PAGE</font></b></p>
    <form name="form1" method="get" action="Detail2.jsp">
    <table width="75%" border="1">
    <tr>
    <td width="20%">
    <div align="center">Sort Parameter </div>
    </td>
    <td width="19%">
    <div align="center">Sort 1</div>
    </td>
    <td width="25%">
    <div align="center">Sort 2</div>
    </td>
    <td width="36%">
    <div align="center">Add Records to Cart:</div>
    </td>
    <td width="36%">
    <div align="center">
    <div align="center">View Cart</div>
    </div>
    </td>
    </tr>
    <tr>
    <td width="20%">
    <div align="center">
    <input type="submit" value="Sort /Select" name="submit">
    </div>
    </td>
    <td width="19%">
    <div align="center">
    <select name="order" size="1">
    <option value="ID" <% if (rsBeachwear__orderby.equals("ID")) {out.print("selected"); } %> >ID</option>
    <option value="Item" <% if (rsBeachwear__orderby.equals("Item")) {out.print("selected"); } %> >Item</option>
    <option value="Color" <% if (rsBeachwear__orderby.equals("Color")) {out.print("selected"); } %> >Color</option>
    <option value="Size" <% if (rsBeachwear__orderby.equals("Size")) {out.print("selected"); } %> >Size</option>
    </select>
    </div>
    </td>
    <td width="25%">
    <div align="center">
    <select name="sort" size="1">
    <option value="ASC" <% if (rsBeachwear__sortby.equals("ASC")) {out.print("selected"); } %>>Ascending</option>
    <option value="DESC" <% if (rsBeachwear__sortby.equals("DESC")) {out.print("selected"); } %>>Descending</option>
    </select>
    </div>
    </td>
    <td width="36%">
    <div align="center">
    <input type="submit" name="Submit" value="Add to Cart">
    </div>
    </td>
    <td width="36%">
    <div align="center">
    <div align="center">
    <input type="button" name="butViewCart" value="View Cart" onClick="window.location='../jserv/Cart2.jsp'">
    </div>
    </div>
    </td>
    </tr>
    </table>
    <p> </p>
    <%while(rsBeachwear.next()){%>
    <table width="75%" border="1">
    <tr>
    <td width="17%">ID:</td>
    <td width="58%"><%=(((rsBeachwear_data = rsBeachwear.getObject("ID"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    <td width="25%">
    <div align="center">Include in Sort:
    <input type="checkbox" name="valueCheckbox" value="<%=(((rsBeachwear_data = rsBeachwear.getObject("ID"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%>" checked>
    </div>
    </td>
    </tr>
    <tr>
    <td width="17%">ITEM:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Item"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%">COLOR:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Color"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%">SIZE:</td>
    <td colspan="3"><%=(((rsBeachwear_data = rsBeachwear.getObject("Size"))==null || rsBeachwear.wasNull())?"":rsBeachwear_data)%></td>
    </tr>
    <tr>
    <td width="17%" bgcolor="#00FFFF" bordercolor="#FFFFFF">
    <div align="left"></div>
    </td>
    <td colspan="3" bgcolor="#00FFFF" bordercolor="#FFFFFF">  </td>
    </tr>
    </table>
    <%
    %>
    <p> </p>
    </form>
    <%
    rsBeachwear.close();
    ConnrsBeachwear.close();
    %>

  • Need help with OCI8::Cursor object

    I'm using ActiveRecord::Base.connection.execute to run a SQL statement against an Oracle schema that is "external" to my Rails database.
    I'm building the connection on the fly using connection parameters stored in my Rails database (MySQL).
    So far so good...I can create the connection and run the query...I'm getting back an OCI8::Cursor object and that's where I'm stuck.
    I need to display the results of the query in a Rails view.
    New to Ruby and I'm not sure how to proceed.
    Here's what I'm getting back:
    #<OCI8::Cursor:0xb76c679c @stmttype=1, @svc=#<OCISvcCtx:0xb76c6c24>, @env=#<OCIEnv:0xb7765928>, @defns=[nil, #<OCIDefine:0xb76c5d10>, #<OCIDefine:0xb76c5cd4>, #<OCIDefine:0xb76c5c5c>, #<OCIDefine:0xb76c5bf8>, #<OCIDefine:0xb76c5bd0>, #<OCIDefine:0xb76c5ba8>, #<OCIDefine:0xb76c5b80>, #<OCIDefine:0xb76c5b58>, #<OCIDefine:0xb76c5b30>, #<OCIDefine:0xb76c5b08>, #<OCIDefine:0xb76c5ae0>, #<OCIDefine:0xb76c5ab8>, #<OCIDefine:0xb76c5a90>, #<OCIDefine:0xb76c5a68>, #<OCIDefine:0xb76c5a40>, #<OCIDefine:0xb76c5a18>, #<OCIDefine:0xb76c59f0>, #<OCIDefine:0xb76c59c8>, #<OCIDefine:0xb76c59a0>, #<OCIDefine:0xb76c5978>, #<OCIDefine:0xb76c5950>, #<OCIDefine:0xb76c5928>, #<OCIDefine:0xb76c5914>, #<OCIDefine:0xb76c58d8>, #<OCIDefine:0xb76c58b0>, #<OCIDefine:0xb76c5888>, #<OCIDefine:0xb76c5860>, #<OCIDefine:0xb76c5838>, #<OCIDefine:0xb76c5810>, #<OCIDefine:0xb76c57e8>, #<OCIDefine:0xb76c57c0>, #<OCIDefine:0xb76c5798>, #<OCIDefine:0xb76c5770>, #<OCIDefine:0xb76c5748>, #<OCIDefine:0xb76c5720>, #<OCIDefine:0xb76c56f8>, #<OCIDefine:0xb76c56d0>, #<OCIDefine:0xb76c56a8>, #<OCIDefine:0xb76c5680>, #<OCIDefine:0xb76c5658>, #<OCIDefine:0xb76c5630>, #<OCIDefine:0xb76c5608>, #<OCIDefine:0xb76c55e0>, #<OCIDefine:0xb76c55b8>, #<OCIDefine:0xb76c5590>, #<OCIDefine:0xb76c5568>, #<OCIDefine:0xb76c5540>, #<OCIDefine:0xb76c5518>, #<OCIDefine:0xb76c54f0>, #<OCIDefine:0xb76c54c8>, #<OCIDefine:0xb76c54a0>], @binds=nil, @ctx=[32, #<Mutex:0xb76c6c38>, nil, 65535], @parms=[#<OCIParam:0xb76c66c0>, #<OCIParam:0xb76c66ac>, #<OCIParam:0xb76c6698>, #<OCIParam:0xb76c6684>, #<OCIParam:0xb76c6670>, #<OCIParam:0xb76c665c>, #<OCIParam:0xb76c6648>, #<OCIParam:0xb76c6634>, #<OCIParam:0xb76c6620>, #<OCIParam:0xb76c65f8>, #<OCIParam:0xb76c65e4>, #<OCIParam:0xb76c65d0>, #<OCIParam:0xb76c65bc>, #<OCIParam:0xb76c65a8>, #<OCIParam:0xb76c6594>, #<OCIParam:0xb76c6580>, #<OCIParam:0xb76c656c>, #<OCIParam:0xb76c6558>, #<OCIParam:0xb76c6544>, #<OCIParam:0xb76c6530>, #<OCIParam:0xb76c651c>, #<OCIParam:0xb76c6508>, #<OCIParam:0xb76c64f4>, #<OCIParam:0xb76c64e0>, #<OCIParam:0xb76c64cc>, #<OCIParam:0xb76c64b8>, #<OCIParam:0xb76c64a4>, #<OCIParam:0xb76c6490>, #<OCIParam:0xb76c647c>, #<OCIParam:0xb76c6418>, #<OCIParam:0xb76c638c>, #<OCIParam:0xb76c62c4>, #<OCIParam:0xb76c61e8>, #<OCIParam:0xb76c6080>, #<OCIParam:0xb76c6058>, #<OCIParam:0xb76c5fcc>, #<OCIParam:0xb76c5fb8>, #<OCIParam:0xb76c5f68>, #<OCIParam:0xb76c5f54>, #<OCIParam:0xb76c5ea0>, #<OCIParam:0xb76c5e64>, #<OCIParam:0xb76c5e14>, #<OCIParam:0xb76c5e00>, #<OCIParam:0xb76c5dec>, #<OCIParam:0xb76c5dd8>, #<OCIParam:0xb76c5dc4>, #<OCIParam:0xb76c5db0>, #<OCIParam:0xb76c5d9c>, #<OCIParam:0xb76c5d88>, #<OCIParam:0xb76c5d74>, #<OCIParam:0xb76c5d60>], @stmt=#<OCIStmt:0xb76c6760>>
    My problem is that I simply don't have a firm enough grasp on the basics of Ruby to dissect this thing and get at it's innards.
    If someone could drop me a code snippet that shows how to reference the contents of this in my erb file I think I'll be off to the races.

    If you want low level access to Oracle database then you can use ruby-oci8 API directly without using ActiveRecord.
    You can read about ruby-oci8 API at http://ruby-oci8.rubyforge.org/en/api.html
    But if you want to use ActiveRecord then install and use oracle_enhanced adapter, see http://wiki.github.com/rsim/oracle-enhanced
    If you have any questions about oracle_enhanced adapter then probably it is better to ask them in http://groups.google.com/group/oracle-enhanced discussion group.
    It is not recommended approach to establish ActiveRecord connection and then use low level ruby-oci8 API.
    And if you have some problem then please describe exactly what you are doing and what you would like to achive and then also what error do you get.

  • JTextArea need help in size

    Hello everyone. I have a quick question. When my program opens I have the window open to the max by getting the screen size dimension. I also have a text area in the frame that I would like do to the same. Any ideas? I have tried setRow, setCol but the problem is these will vary across computers. I tried textArea.setSize(dimension of screen) but this only accounts for the cols, not rows so it sizes the cols to the max but not the rows.

    Gotcha, ok I must be doing something wrong somewhere. Thanks for helping me out, I will post my code. Also, looking back at my code I was not using border layout so this may have been the problem. Can you take a peak though? It may be something else. I would basically like the text area to resize when the window does but always fill up all the space under the menu. If I can get this working I'm almost done since all the functionality works. I left out that code though to shorten this up some, I mainly added the code where I create and add the panel to the frame.
    This is the driver, basic creation of the frame
    import javax.swing.JFrame;
    import java.awt.*;
    public class Run {
      public static void main(String args[]) {
        Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
        Notepad n = new Notepad();
        n.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        n.setSize(screenSize);
        n.setVisible(true);
    }Here is the panel where I store the text area
    I also use this class to handle operations on the text area such as reading/writing to disk etc. I left out the functionality code to keep it small and to the point.
    public class NotepadFile extends JPanel {
      private JTextArea mainTextArea;
      public NotepadFile( ) {
        setLayout(new FlowLayout()); //default 
        mainTextArea = new JTextArea();
        mainTextArea.setLineWrap(true);
        add(mainTextArea);     
    }Finally, here is where I add the panel to the main frame. Again, i'm leaving out the functionality code like event handlers and such.
    public class Notepad extends JFrame {
      private NotepadFile nFile;
      private final int fileMenuIndex = 0,
                  formatMenuIndex = 1,
                  helpMenuIndex = 2;
      public Notepad( ) {
        super("Notepad");
        JMenuBar mainMenuBar;
        JMenu menu[];
        nFile = new NotepadFile();
        mainMenuBar = new JMenuBar();
        setJMenuBar(mainMenuBar);
        menu = new JMenu[menuNames.length];
        for(int i=0;i<menuNames.length;i++) {
          menu[i] = new JMenu(menuNames); //create a menu
    menu[i].setMnemonic(menuMnemonic[i]);
    //here is where I created menu items but I cut it out here
    //continued..
    for(int i=0;i<menuNames.length;i++)
    mainMenuBar.add(menu[i]); //add menus to menu bar
    add(new JScrollPane(nFile));
    //here I also tried add(new JScrollPane(nFile), BorderLayout.CENTER); but it didn't work

  • NEED HELP! passing an object array to a method

    Hi, i need to make a method called public Server[] getServers() and i need to be able to see if specific server is available for use.
    I have this so far:
    public abstract class AbstractServer
    protected String serverName;
    protected String serverLocation;
    public AbstractServer(String name,String location)
    this.serverName=name;
    this.serverLocation=location;
    public abstract class Server extends AbstractServer
    public Server(String name,String location)
    super(name,location);
    public class CreateServers
    Server server[];
    public CreateServers()
    public Server create()
    for(int i=0; i<10; i++)
    server=new Server(" ", " "); //i was going to fill in something here
    return server;
    OK NOW HERE IS THE PROBLEM
    i have another class that is supposed to manage all these servers, and i dont understand how to do the public Server[] getServers(), this is what i have tried so far
    public class ServerManager()
    public Server[] getServers(Server[] AbstractServer)
    Server server=null; //ok im also confused about what to do here
    return server;
    in the end i need this because i have a thread class that runs the servers that has a call this like:
    ServerManager.getServers("serverName", null);
    Im just really confused because i need to get a specific server by name but i have to go through AbstractServer class to get it
    Any help?

    ok, right
    since i have to call this method in the thread class saying
    ServerManger.getServer(AbstractServer[]) //to see if i have all the servers i need to proceed
    im confused about how it should be declared in the actual ServerManager
    should it be like
    public Server[] getServers(AbstractServer[]) ???? and then have it return all the servers it has
    thats the part i dont get, because instead of saying ServerManager.getServer(string, string) i want it to go and find out if i have all the servers i need to continue
    does that make sense? sort of?

  • Need Help for Array with Object

    hey there guys... am trying to complete my project which is to create a Library System. Was able to create a list to show the books available when they select the book and click a borrow button it can print out the book.
    what problem i have now is that when a student click borrow... the value how can i transfer to an array inside the object student.
    i am usin a main screen (ms) who is controlling all the functions. been trying and trying on this for very long hopefully there will be those who are able to help me out.
    my customer screen would be like this... but how can i add in the array for books borrowed
    import javax.swing.*;
    class Customer
         private String name;
         private int accNo;
         private String password;
         private double balance;
         private Books borrow[]=new Books[5];
         int borrowCount=0;
         static int customerCount=0;
         private MainScreen ms;
         Customer(String n, int no, String p, double b)
              name=n;
              accNo=no;
              password=p;
              balance=b;
              customerCount++;
              JOptionPane.showMessageDialog(null,name +" record created");
              display();
    /* Trying to Create the Array to store information
         public void setStudentBorrow(String a)
              borrow[borrowCount]=a;
              borrowCount++;
              JOptionPane.showMessageDialog(null,"Book Borrowed");
         public String getStudentBorrow()
              for(int i=0;i<borrowCount-1;i++)
              {     return borrow;     }
         public String getPassword()
         {     return password;     }
         public String getName()
         {     return name;          }
         public int getAccNo()
         {     return accNo;     }
         public double getBalance()
         {     return balance;     }
         public void setName(String n)
         {     name=n;     }
         public void setPassword(String p)
         {     password=p;     }
         public void setBalance(double b)
         {     balance=b;     }
         public void setAccNo(int no)
         {     accNo=no;     }
         public void display()
              JOptionPane.showMessageDialog(null,
              "\nCutomer Number : "+ customerCount+
              "\nName :"+name+
              "\nAccount Number: "+accNo+
              "\nBalance (RM): "+balance,"Customer record",
              JOptionPane.INFORMATION_MESSAGE     );

    Cross Post:
    http://forum.java.sun.com/thread.jspa?threadID=779224&messageID=4433689#4433689

  • Need help serialize a collection object

    I have a class that's going to manage a list of paths stored as strings as "ArrayList<String> fileList = null;". I can't figure out how to serialize the fileList object. The class that contains the fileList implements Externalizable. here are the read and write functions:
         public void readExternal(ObjectInput in) throws IOException
              fileList = (ArrayList)in.readObject();
         public void writeExternal(ObjectOutput out)  throws IOException//, ClassNotFoundException
              out.writeObject(fileList);
         }I've tried lots of different things and nothing works. Anybody know how to serialize an ArrayList? Is ArrayList the best class for the job?

    I have a class that's going to manage a list of paths
    stored as strings as "ArrayList<String> fileList =
    null;". I can't figure out how to serialize the
    fileList object. You don't have to do anything to serialize ArrayList, it is already Serializable.
    The class that contains the fileList
    implements Externalizable. here are the read and
    write functions:I will assume there is a good reason this class (that contains the fileList) can itself not be Serializable and needs to be Externelizable.
    >
    public void readExternal(ObjectInput in) throws
    s IOException
              fileList = (ArrayList)in.readObject();
    public void writeExternal(ObjectOutput out)  throws
    s IOException//, ClassNotFoundException
              out.writeObject(fileList);
         }I've tried lots of different things and nothing
    works. Anybody know how to serialize an ArrayList? Is
    ArrayList the best class for the job?I tried the same example -- with code to make it compilable and testable -- and it works as expected.
    What exactly do you mean when you say "nothing works"?

  • Need help on XI Action object.

    I am new to XI...
    Following the blog of Sarvya talanki...
    working on this blog n getting some message while trying to connect the action. I am not getting the option what is displayed in the blog.
    /people/venkat.donela/blog/2006/02/17/companion-guide-to-integration-scenario
    while trying to connect the action the message is.
    To open or create a connection, select the second action and call the context menu
    can anyone help how to proceed further...

    hi Syed,
    You have to select both the actions:
    it can be done in two ways:
    1. select first -> press shift and select second and now right click on any one.
    2. selct both of them with mouse .. strat from top left corner and click now drag down to select the actions:
    Regards,
    Sachin

  • Need help with Shockwave flash object by adobe systems it's an add ons

    Please any help you can give me as I can't figure
    out what is wrong I disable the add on but then I can't load any of
    my games without it but when it is enabled I keep getting the fatal
    error browser must close, the only options that I have are to
    enable it or disable it and neither one is working properly for me
    so PLEASE help me and tell me what I can do to resolve this
    stubborne issue!!!! Thanks Treblinka4444

    Please any help you can give me as I can't figure
    out what is wrong I disable the add on but then I can't load any of
    my games without it but when it is enabled I keep getting the fatal
    error browser must close, the only options that I have are to
    enable it or disable it and neither one is working properly for me
    so PLEASE help me and tell me what I can do to resolve this
    stubborne issue!!!! Thanks Treblinka4444

  • Re: need help to create document object

    Hi there,
    I am new to C3PO stuff and would anyone kindly give me a hand? I am trying
    to create a Document object out of the Message object, but it always give
    me error:
    err.description= object required
    err.number=438
    err.helpcontext= 1000424
    here is the actual code using VB
    ==========================================
    Dim objSelectedMessages As Object
    Dim objMessage as Object
    Set objSelectedMessages = g_C3POManager.ClientState.SelectedMessages
    Set objSelectedMessages = objSelectedMessages.Find("(DOCREFERENCE) AND
    (<Document Status, STRING> CONTAINS NOT ""Final"")")
    For Each objMessage In objSelectedMessages
    DoSomething objMessage.Document
    Next
    ==========================================
    Everything works great before we upgrade to GroupWise 7(from ver. 6)...
    Thanks for reading this post.
    Sincerely,
    Philip

    Thanks Michael and Glade, I really appreciate the input.
    I am sorry that I should have include the doSomthing method code, here it
    is:
    here is the actual code using VB
    ==========================================
    private sub CheckDocFinalStatus()
    Dim objSelectedMessages As Object
    Dim objMessage as Object
    Set objSelectedMessages =
    g_C3POManager.ClientState.SelectedMessages Set objSelectedMessages
    = objSelectedMessages.Find("(DOCREFERENCE) AND
    (<Document Status, STRING> CONTAINS NOT ""Final"")")
    For Each objMessage In objSelectedMessages
    DoSomething objMessage.Document
    Next
    end sub
    private sub doSomething(byval ADocument as object) <-- error occurs here
    If ADocument is nothing then
    else
    end if
    end sub
    ==========================================
    The error occurs as soon as I called doSomething Method, it won't allow me
    to create the document object at all. Seems to be missing a reference in
    my development environment because when I looked at the vb6 intellisense,
    there is no child object for the message.document.
    I know this is silly but is message.document object part of the GW Object
    API, right? I think I am missing something...
    And I will definitely install the GW7 SP1 as soon as possible and keep you
    guys update how it goes.
    Really appreciated.
    Thanks,
    Philip
    PCode2006 wrote:
    > Hi there,
    > I am new to C3PO stuff and would anyone kindly give me a hand? I am trying
    > to create a Document object out of the Message object, but it always give
    > me error:
    > err.description= object required
    > err.number=438
    > err.helpcontext= 1000424
    > here is the actual code using VB
    > ==========================================
    > Dim objSelectedMessages As Object
    > Dim objMessage as Object
    > Set objSelectedMessages = g_C3POManager.ClientState.SelectedMessages
    > Set objSelectedMessages = objSelectedMessages.Find("(DOCREFERENCE) AND
    > (<Document Status, STRING> CONTAINS NOT ""Final"")")
    > For Each objMessage In objSelectedMessages
    > DoSomething objMessage.Document
    > Next
    > ==========================================
    > Everything works great before we upgrade to GroupWise 7(from ver. 6)...
    > Thanks for reading this post.
    > Sincerely,
    > Philip

  • Need help for finding objects impacted by size change for an infoobject

    hi all,
    need help for finding objects impacted by size change
    for xxx infoobject, due to some requirements, the size to be changed from
    char(4) to char(10), in the source database tables as well as adjustment
    to be done in BI side.
    this infoobject xxx is nav attribute of YYY as well as for WWW
    infoobjects. and xxx is loaded from infopkg for www infoobject load.
    now that i have to prepare an impact analysis doc for BI side.
    pls help me with what all could be impacted and what to be done as a
    solution to implement the size change.
    FYI:
    where used list for xxx infoobject - relveals these object types :
    infocubes,
    infosources,
    tranfer rules,
    DSO.
    attribute of characteristic,
    nav attribute,
    ref infoobject,
    in queries,
    in variables

    Hi Swetha,
    You will have to manually make the table adjustments in all the systems using SE14 trans since the changes done using SE14 cannot be collected in any TR.
    How to adjust tables :
    Enter the table name in SE14. For ex for any Z master data(Say ZABCD), master data table name would be /BIC/PZABCD, text table would be /BIC/TZABCD. Similarly any DSO(say ZXYZ) table name would be /BIC/AZXYZ00 etc.
    Just enter the table name in SE14 trans --> Edit --> Select the radio button "Save Data" --> Click on Activate & adjust database table.
    NOTE : Be very careful in using SE14 trans since there is possibility that the backend table could be deleted.
    How to collect the changes in TR:
    You can collect only the changes made to the IO --> When you activate, it will ask you for the TR --> Enter the correct package name & create a new TR. If it doesn't prompt you for TR, just goto Extras --> Write transport request from the IO properties Menu screen. Once these IO changes are moved successfully, then the above proceduce can be followed using SE14 trans.
    Hope it helps!
    Regards,
    Pavan

Maybe you are looking for