API for retrieving processor data
does anyone here know which java API is used to retrieve data from the processor.....Kinda like system monitoring tool which is able to retrieve the state of processor and display it through graph.......
Besides System and Runtime, I don't think there's much. This would at least give you some memory information. There may be a third party package (maybe check SourceForge), but I don't know of one).
You could potentially make calls to the OS using the exec command in Runtime. You could use the properties in System to figure out the platform and go from there. Take a look at this post for more info on using exec.
http://forum.java.sun.com/thread.jsp?forum=57&thread=125678
Good luck
Similar Messages
-
Interface for retrieving CVS data
Hi
I want to write an interface for retrieving cvs data,like the last person toupdate the file,the last date and everything visible in cvs log..
Can anyone help me in designing the interface,and also is there any api's available for this
Please reply soon..
Thanks and regards
SumitFor simple CSV files that you generate yourself, that should indeed be more than enough. The standard CSV files that most applications output have some more rules however, and Excel breaks those rules
(sigh).
Check this out:
http://ostermiller.org/utils/CSV.html -
APIs for Retrieving properties from portalapp.xml
Hi all,
Can anyone tell me Is there any Java/Portal APIs for retrieving properties from portalapp.xml as well as from manifest.mf.
Help wud be highly appreciated.
Regards,
KarthickHi Karthick,
If you want to access the manifest file, you could do something like this:
import java.io.File;
import java.io.FileInputStream;
import java.util.jar.Manifest;
import com.sapportals.portal.prt.runtime.IPortalRuntimeResources;
import com.sapportals.portal.prt.runtime.PortalRuntime;
File privateResoucePath = PortalRuntime.getRuntimeResources().getLocation(IPortalRuntimeResources.LT_PRIVATE_RESOURCES);
File parPath = new File ( privateResoucePath, "HelloWorldProject" ); // name - par file name without the ".par" extension);
if ( parPath.exists()!=false ) {
try {
File manifestPath = new File ( parPath, "META-INF" );
FileInputStream fis = null;
fis = new FileInputStream(new File(manifestPath, "MANIFEST.MF"));
Manifest mf = new Manifest(fis);
java.util.jar.Attributes attr = mf.getMainAttributes();
if (attr!=null) {
return attr.getValue("Specification-Title");
else {return null;}
} catch (Exception e) {
e.printStackTrace();
return "ERROR"+e.toString();
META-INF is top level folder.
Hope this helps.
Daniel -
Sql queries for retrieving setups data for functional modules
Hi,
Can anyone give me the sql queries for retrieving setups data for functional modules (GL, AP, AR, FA, and CM) from Database.Hi,
Can anyone give me the sql queries for retrieving setups data for functional modules (GL, AP, AR, FA, and CM) from Database. -
Issue with update_task API for updating Scheduled Dates for Task..
Hi All,
We have a requirement to update the project and task dates to a specified period from the current dates. I dont want to update all the tasks, and hence using the update_task API. The scheduled_finish_Date is the column from "pa_proj_elem_ver_schedule" which we want to update. As, this is the date which is shown on the Workplan tab for the tasks for (Scheduled Start and Scheduled Finish Date). I want to extend this scheduled_finish_Date to some days , say for eg. 60 days.
To achieve, that update_task api is being used and the parameter for the scheduled_date is : p_scheduled_finish_date, this is passed as call to pa_project_pub.update_task API.
We are also updating the completion data, which is happening fine and is updating the pa_tasks : completion_date column.
Problem is with scheduled date, Please let me know how to go about this issue.
Here is the sample code for calling the API :
pa_project_pub.update_task
(p_api_version_number => l_api_version_number_i,
p_commit => l_commit,
p_init_msg_list => l_init_msg_list,
p_msg_count => l_msg_count,
p_msg_data => l_msg_data,
p_return_status => lt_return_status,
p_pm_product_code => l_pm_product_code,
--p_structure_updates_flag => g_no,
p_pm_project_reference => l_proj_reference,
p_pa_project_id => p_project_id_i,
p_pm_task_reference => p_pm_task_reference_i,
p_pa_task_id => p_task_id_i,
p_task_name => p_task_name_i,
p_task_number => p_task_number_i,
p_pa_parent_task_id => p_parent_task_id_i,
p_task_completion_date => p_tsk_actual_finish_date_i,
--Transaction Date (shown on the screen)
p_scheduled_finish_date => p_tsk_sched_end_date_i,
-- Scheduled Date (shown on the screen)
p_out_pa_task_id => l_pt_task_id,
p_out_pm_task_reference => l_pt_task_ref
I am really not sure if I am missing anything here, please suggest as to how to update the Schedule Start and Finish Dates using the API.
Waiting in anticipation!
Thank you
Anand.Hello,
Make sure the wf is active in QA (re-activate if possible), check the transport for errors, check authorizations for WF-BATCH perhaps delete and recreate via SWU3?), refresh the buffers (SWU_OBUF).
Please let me know if any of this helps.
regards
Rick Bakker
Hanabi Technology -
Open ended data structure for retrieving SQL data
I have a flex project that reads data from a database and
sends it to my flex app to display in a chart. I need to do this in
Actionscript since I have to dynamically create different charts
based on the database definitions. Up til now, I have inserted the
data for each series into a separate
ArrayList(java)/ArrayCollection(flex) in this way:
BindingUtils.bindProperty(lineSeries, "dataProvider", series,
"pointList");
lineSeries.xField="point1";
lineSeries.yField="point2";
The series variable is a custom Actionscript/Java object
which contains an ArrayCollection called pointList. And the array
is made up of custom DataObjects with two fields, point1 &
point2.
But in the new paradigm, I'd basically like to create a big
array of arrays similar to a database table and then just point the
xField to one column, and the yField to another column. Anyway, it
seems like the problem is that my point1 and point2 in the current
implementation are variable names, but with this new dynamic
structure, I won't be able to create variables on the fly. So how
do I let flex know to look at column 3, for example for the yField?
The attached code is from the Flex documentation and is an example
of what I'd like to emulate (except I need to do it in
actionscript). I'd like to be able to select "month" or "amount",
etc. But coming from the Java side, there is no way for me to name
the array contained in each column.I guess I wasn't clear enough. I am actually serializing a
java object and mapping it to an actionscript object via blazeDS. I
know about how the objects translate, for example for
ArrayCollections in flex, I use ArrayLists in java. The problem is
that I'm not sure how to get the associative aspects of the arrays
in flex into my java data structures in a way that will translate
to the way flex can define arrays, such as Month:"January".
It seems that in flex, you can create an Array and assign it
an element like {month:"January", amount:"450"} and it will create
an Object with variables for month and amount. But I don't know how
to do this on the fly in Java (or in Actionscript for that matter)
when I have no way of knowing beforehand how many variables my
object will need. Each series will need an x and y, though usually
the x will be dates which are the same for each series. So if I had
10 series sharing an axis, I'd need 11 variables in my object-
date, series1, series 2...series 10. -
Help for retrieve xml data from database.
Hello friends,
I am inserting xml file into oracle database.
column name is xyz_xml and data type is XMLType.
I have successfully inserted that.
But My problem is How can i retrieve that xml file from database and can view in explorer as a text.
If any one have any idea than let me know.
ThanksHello Friend...!
I am getting the following error and i am not figure out this error :
NosuchfieldException : conversionPlease Help me. -
Are there REST APIs to retrieve entity metadata for eloqua objects?
There is a list of all the objects which can be accessed by REST for CRUD in this link: REST API - Documentation for Core Objects under the Core Objects section.
For each of the objects listed under the Core Objects section are there is a field metadata under the Properties section.
For example for Email object, REST API - Accessing Emails , under the Properties section, there corresponding entries for fields of Emails object under the
Name ,Type, Description and Validations headings.
Is there a REST API for retrieving the same information i.e. the field metadata for an eloqua object programmatically ?
If not , it is a serious hindrance to building systems that are metadata driven and also since SOAP support is being deprecated...Metadata is 'top level' information on the object, and available whether you query the individual object (a single form, or email asset) or query for multiple objects of that type (list all forms, list all emails). Consider using a depth of minimal or partial for faster performance if the specific configuration of those objects is not important..
Example:
GET /assets/forms?depth=minimal&count=2
Returns:
"elements":
"type":"Form",
"currentStatus":"Draft",
"id":"19",
"createdAt":"1409623550",
"createdBy":"8",
"depth":"minimal",
"folderId":"7",
"name":"zzztestCS_3-9381543541_AutocompleteTest",
"permissions":"fullControl",
"updatedAt":"1409623623",
"updatedBy":"8"
"type":"Form",
"currentStatus":"Draft",
"id":"22",
"createdAt":"1409781207",
"createdBy":"11",
"depth":"minimal",
"folderId":"466",
"name":"daisychain1",
"permissions":"fullControl",
"updatedAt":"1412779449",
"updatedBy":"20"
"page":1,
"pageSize":2,
"total":130
Without limiting the count to 2, this would return up to 1000 results if you had multiple forms in your system and give you a basic top level view of each. Similarly, you can use GET /assets/form/{id}?depth=minimal to get the same sort of information.
Other endpoints can be found on the REST livedocs page here (requires authentication):
https://secure.eloqua.com/api/docs/Dynamic/Rest/1.0/Reference.aspx
Regards,
Bojan -
Design ideas for retrieving Data for Read Only
Hi All,
Currently I am in the process of evaluating different design ideas for the search functionality of my application. I am looking for a best option for retrieving the data by executing some complex sql queries with huge query criteria and showing the single or multiple records to the user. But the data is read only. This may involve pagination if the number of records exceeds the page limit.
There are various options to implement this like JDBC and JDO or using some persistance framework to retrieve the data objects. Please suggest me about a good option for this.
Thanks in Advance
DurgaCurrently I am in the process of evaluating different
design ideas for the search functionality of my
application. I am looking for a best option for
retrieving the data by executing some complex sql
queries with huge query criteria and showing the
single or multiple records to the user. But the data
is read only. This may involve pagination if the
number of records exceeds the page limit. This can typically be handled with a Fast Reader, though this is a coding ideom rather than a true design pattern.
http://java.sun.com/blueprints/patterns/FastLaneReader.html
Please suggest me about a
good option for this.Apache Lucene is worth considering,
http://lucene.apache.org/java/docs/ -
Adobe Form with XML interface cannot retrieve all data from SAP
hi all
I want to use the Adobe forms for the real estate module.
I had seen that adobe forms can have an interface with XML input and output as parameter.
In the interface type only the /DOCPARAMS an the DOCXML are INPUT parameters which are available.
No other INPUT parameter can be added to it.
When i try to retrieve the data in real estate there are some default function modules for retrieving the data from real estate.
But this function modules also are going to find out if the form which asks for this information has a IMPORT parameter
for the required data. For example, the SENDER data is retrieved, but before the default function module retrieve this data
the function module checks if the form has a INPUT parameter SENDER.
And that is not the case. And i cannot create the SENDER parameter to it, because this INTERFACE type does not allow it.
Does anybody know a solution herefore?
kind regards,
Anton PierhagenHi Bhaskar
It is a long time ago, almost 2 years.
I created my own custom development for calling the Adobe form. This custom development uses the correct function module interface with the IMPORT XML.
The XML which i sent as IMPORT PARAMETER to the form is also created by own custom development. Via the default XML class of SAP
So that was my solution
Kind regards,
Anton Pierhagen -
IRoom API and retrieve room document's properties
Hi, everyone, a room has been created and some
documents have been uploaded in it. Now I need to make a test program to retrieve the selected documents properties like document's type, size, author etc. Which API should I use? How can I know which document is being copied, moved or renamed etc? Thanks for early reply.
BR.
WangHi can any one tell me if there is API for retrieving document's properties, where is the jar file, what is the jar name ? where is the documentation ? Thanks for reply. I am working on EP 6.0 SP2 P27 and Eclipse 2.1.
Thanks for reply.
BR.
Wang -
GetItemData integration api: unable to read data for custom item
Hello,
I am trying to retrieve the data of an custom item via the getItemData api but i am gett the error message
"Not implemented for this item type"
I checked the api documentation, the list of supported item types include custom methods.
Is there any thing that i need to maintain for the custom method so that i can read the data stored by it using the getItemData api.
or is it simply not possible to read custom item data.
Thanks for the help,
Regards,
SauravHi Ruediger,
Thanks for the reply.
To test the getItemData API i have implemented the hello world custom method example (java script).
I created an item using the UI and edidted the content.
when i try to read the saved data using the api i am getting the message
encountered an error:
Server returned HTTP response code: 400 for URL: https://streamwork.com/v1/items/5EXAbr-TgVCJV1qgL8-g1W/item_data?
<?xml version="1.0" encoding="UTF-8"?>
<error>
<http_status>400 Bad Request</http_status>
<message>Not implemented for this item type.</message>
</error>
When i try to read the data of a text item using the same API I am getting the correct response
<text_item>
<text_content><p>Hello testing</p></text_content>
</text_item>
So i was wondering how i can implement the getItemData for my custom method.
Thanks and regards,
Saurav. -
After a Lion clean install, how do I retrieve my data from external hard drive?
Following Apple advice I used Migration Assistant which crashed new system twice which is why I had to clean install Lion in the first place.
Is there a sure way of doing it?
I have only a few programs that I will have to install myself and that should not be a problem.
I just want my data, music and photos back where I can use them.Time machine backups. I went to migration assistant a few hours ago and limited my selection to "users", no need for applications, settings and other files. Stuff started moving over at a fast pace but has now seemed to stall.
I will let it run overnight as there are lots of songs and photos as well as a few movies.
If that does not work, then I will go into TM and try restore. I have restored some things in the past such a mail files and it has worked well.
The Apple fellow at the store told me to go right into TM, he may have had a point. I'll get it eventually. -
How to retrieve the data from a jsp page for print?
i have a dynamic jsp file which will get the data at runtime.I have a print button in the jsp.When i chick the print button it should capture the data from the jsp and print it as LANDSCAPE mode. Now i am using Java Api for this
Following code is a working sample which prints some data in LANDSCAPE mode..This is working fine....How can i modify this to get the data from a jsp?....I am using weblogic workshop for development
package Awtjava;
//working example
import java.awt.*;
import java.awt.print.*;
public class testPrint implements Printable {
private static String s[];
private static Font f;
private static int nLines;
public static void main (String arg[]){
s = new String[10];
f = new Font("Arial", Font.PLAIN, 11);
int i;
s[0] = "This is a printer test";
for (i=1; i<10; i++){
s[i] = "The next line";
nLines = 10;
testPrint.printa();
public static void printa(){
System.out.println("public static void printa () ");
PrinterJob pj=PrinterJob.getPrinterJob();
Book b = new Book();;
PageFormat pf = new PageFormat();
pf = pj.defaultPage(pf);
b.append(new testPrint(), pf, 2);
pj.setPageable (b);
try{
if (pj.printDialog()){
pj.print();
catch (Exception e) { System.out.println ("Error"); }
public int print (Graphics g1, PageFormat pf, int n){
System.out.println("public int print");
int x,y,i,fa,fh;
FontMetrics fm;
Graphics2D g = (Graphics2D) g1;
pf.setOrientation(PageFormat.LANDSCAPE);
fm = g.getFontMetrics (f);
fa = fm.getMaxAscent();
fh = fm.getHeight();
x = (int)pf.getImageableX();
y = (int)pf.getImageableY() + fa;
g.setFont (f);
g.setColor(Color.black);
if (n==1){
for (i=0; i<10; i++){
g.drawString (s, x, y);
y += fh;
return PAGE_EXISTS;
else {
for (i=10;i<10; i++){
g.drawString (s[i], x, y);
y += fh;
return PAGE_EXISTS;
Hope you will reply soon...
Thanks in advance
MariaHey, I got a doubt that who will call the print method in the same program and what about the g.drawString() it is showing any output effect. Finally how the variable n will get initializing to 0 and 1 for two times respectively. Can u please elaborate on this...
-
How to use the API for DATE, MONTH AND YEAR
I would like to use the java api in .util.calender in the java api to get the date.
How to implement the API for the "DATE","MONTH","YEAR" which are available provide by java?
can someone give me in one complete code?From the Java Developers Almanac 1.4:
Calendar cal = new GregorianCalendar();
// Get the components of the date
int era = cal.get(Calendar.ERA); // 0=BC, 1=AD
int year = cal.get(Calendar.YEAR); // 2002
int month = cal.get(Calendar.MONTH); // 0=Jan, 1=Feb, ...
int day = cal.get(Calendar.DAY_OF_MONTH); // 1...
int dayOfWeek = cal.get(Calendar.DAY_OF_WEEK); // 1=Sunday, 2=Monday, ...
Maybe you are looking for
-
Do I HAVE to start the cloud on an Apple product before putting it on my pc???? I have no Apple products but desire to use the i cLOUD WITH MY Win 9 , 64 bit PC. IF my PC is up to date can I START using the I Cloud on my PC first? do not want to dow
-
I have to modify the report output in about 6 different reports thats written with ABAP. I am looking for some type of tool to help me to rewrite the screen output. It's very tedious to write the code using the 'Write AT' command because these repo
-
Session timeout in OBIEE11g brings Oracle annoyances to new level.
There is not a single place you can configure that sixteen-minute timeout from bothering the crap out of your users. There are lots of timeout settings in various configuration files, but none of them control this particular annoyance. I just rolled
-
Subcribe a Portal User Group to content change events on page?
Another developer at my shop has created a custom routine that programmatically subscribes the given user to content change events on a page. At the heart of their custom routine are the following Oracle Portal API calls: portal.wwctx_api_private.set
-
I cant get my ipad air2 to connect to iTunes on my computer
I cannot get my iPad Air2 to connect to iTunes on my computer