How do I get and set the double field in a Double?
Thanks - this has to be easy but I cant find documentation
It's immutable, so you have to provide the value when you create it:
Double a = new Double(18.76);
Double b = new Double("18.76");
Double c = Double.valueOf(18.76);
Double d = Double.valueOf("18.76");
Double e = Double.parseDouble("18.76");Going from Double to double is easy -- I'm surprised you didn't see it in the API:
double x = a.doubleValue();Again, Doubles are immutable, so there is no way to change the double value of a Double object.
Similar Messages
-
How do I get and set column attributes in a table or a treetable with Java?
Using 11.1.1.4.0
Hi,
How do I get and set column attributes in a table or a treetable with Java? For a simple example, say I have a table and want certain roles to see all columns (including address), and other roles can see only certain columns (no address). In a Java method, I want to test if a table's column visible attribute is true and if so, set it to false before rendering it.
Thanks in advance,
TroyHi,
this use case would be a perfect example for using seeded MDS customization. Instead of checking what users are allowed to see or not upon rendering time, you have a customization class and thus the framework doing this for you.
http://www.oracle.com/technetwork/developer-tools/adf/learnmore/31-mds-sample-169173.pdf
In this paper and sample, specific users see different layouts. It also contains a customization class that shows how this can leverage ADF Security
Frank -
How do I get and set cookies with JSF?
How do I get and set cookies in a JSF managed bean?
Regards,
Al MalinBelow is how I did it...I am receptive to improvements.
FacesContext facesContext = FacesContext.getCurrentInstance();
HttpSession session = (HttpSession)facesContext.getExternalContext().getSession(false);
HttpServletRequest request = (HttpServletRequest)facesContext.getExternalContext().getRequest();
HttpServletResponse response = (HttpServletResponse)facesContext.getExternalContext().getResponse();
String cookieName = "myCookieName";
Cookie requestCookie = null;
Cookie[] cookies = request.getCookies();
logger.info("looking for cookie...");
if (cookies != null)
for (int i = 0; i < cookies.length; i++)
if (cookies.getName().equals(cookieName))
requestCookie = cookies[i];
logger.info(cookieName + " = " + requestCookie.getValue());
logger.info("done looking for cookie");
Cookie responseCookie = new Cookie(cookieName, "myCookieValue");
responseCookie.setPath("/");
response.addCookie(responseCookie); -
How can I get and change the items grid of MIRO trx
Hi everyone,
I have a requirement where I need to get and change the tax code field in MIRO's item grid. Is there a function module / Badi to do this? I used MRM_HEADER_CHECK, but the parameters related with this badi only allows read but not change them.
Do you have any idea?
Thanks in advance!
Regards.
Leo.Hello,
You can change that table with help of the filed-symbol in the BADI MRM_HEADER_CHECK.
LOOP AT ti_drseg INTO ls_drseg.
lv_index = sy-tabix.
***... do your processing
MODIFY ti_drseg FROM ls_drseg INDEX lv_index.
ENDLOOP.
FIELD-SYMBOLS: <drseg> TYPE mmcr_tdrseg.
ASSIGN ('(SAPLMR1M)ydrseg[]') TO <drseg>.
<drseg> = ti_drseg[]. " this will modify the data in MIRO with your modified data
Regards,
Naimesh Patel -
How to get and set the column order in SharePoint list forms
Hi,
I want to read the column order of the SharePoint list forms in SharePoint 2003 sites using any of the available web services and need to set the same order
in the newly created list in SharePoint 2010.
I am able to read the fields from SharePoint 2003 and creating the list with same fields in SharePoint 2010, but the column order is not maintaining in
list forms.
Also, I need to created the views from 2003 site to 2010 site.
Please help me...
Thanks in advance...Hi,
Please try to use the following code to programatically change the order.
SPList list = web.Lists["Example List"];
if (list.ContentTypes.Count > 0)
SPContentType ct = list.ContentTypes[0];
string[] names = {"Example_x0020_One", "Example_x0020_Two", "Example_x0020_Three"};
ct.FieldLinks.Reorder(names);
ct.Update();
Here is a similar thread for your reference:
https://social.technet.microsoft.com/Forums/en-US/ce66fd65-2882-4bda-8142-89e116d8b90f/how-to-set-the-order-of-the-fields-in-list-forms?forum=sharepointdevelopmentprevious
Best Regards
Dennis Guo
TechNet Community Support -
Help, how to install jvm and set the classpath using a batch file
hello,
i have created my java application and now have to create an installable / batch file which will install the JVM on the users machine and also the java packages such as javamail and the class files that i have created . it also has to set the classpath.
i would like to know if anyone can tell me how to go about iti.e. how can i install the JVM using a batch file and then place the javamial packages etc in the apropriate directory .
or is it advisable to explain it to the user how to go about it in tht user manual.
and would also like to know that if i install the JVM will the path for the java.exe be set
or will i have to set the path explicitly from the "batch file" so that the user can run the application without and problem just by running the java command followed by filename from the command prompt.hi,
I have windows and I use it.
The only problem with the free edition is that you can only create 1 launcher and that during the installation you get 1 popup showing that the installer was created with an unregistered version.
Stijn -
How to account for and set the temperatur​e in testing
The problem is this: I'm setting up an airflow resistance test and I need to account for temperature and barometric pressure. However, I don't know how to setup LabVIEW to account for these variables.
Devont:
Actually this issue is a fairly complex problem in aerodynamics. I am
an aerospace engineer who has developed computer code for this very
purpose in a couple of wind tunnels. When you say you are setting up
an airflow "resistance" test, what physical (aerodynamic) properties
are you trying to measure? Tunnel flow velocity? Mass flow?
Aerodynamic properties on a test model? (lift and drag coefficients,
center of pressure, gross forces?)
If you are trying to measure air flow velocity through a wind tunnel
test section, then the next question is what type of sensor system are
you using to do this? A pitot-static probe? A hot wire anenometer?,
an LDV (doppler laser)? Each has different techniques for getting
back flow properties.
Also what kind of tunnel is this? Low speed subsonic (say less <100
M/s) Mid speed subsonic <0.6 Mach? Transonic 0.8 to 1.2 Mach?
Supersonic 1.2 to 4.0 Mach? Hypersonic (say >4.0 Mach?) This will
make a great deal of difference in computing flow properties.
Mach number is a ratio of the flow velocity to the local speed of
sound where;
M=v/a where a is the speed of sound.
a=(gamma*r*t)^0.5
where gamma is the ratio of specific heats Cp/Cv, r is the gas
constant, and t is the absolute temperature. Gamma is a constant up to
about mach 4 but really starts to fall apart after that so this speed
of sound equation becomes a lot less useful for hypersonic analysis.
At low speeds gamma for air is approximately 1.4, r is about 287 for
air. At STP, the speed of sound is about 340 meters/second.
What is the scale of your tunnel? What is the density altitude of
your tunnel? What is the fluid medium in your tunnel? (Is it regular
air or something else?) These play into computing flow properties
because they affect a dimensionless flow property called the Reynolds
number which affects how the flow in the tunnel behaves.
You will need to consider also humidity which affects the density of
the fluid medium in your tunnel. Water vapor has a molecular weight
of 18. Dry air (0% RH) has a molecular weight of about 28.9. The
more water vapor you have, the lighter the sample volume of "air" will
be. The ability of air to retain water vapor is a function of
temperature, so a relative humidity of 100% at 0 degrees C will
contain much less water vapor than a relative humidity of 20% at 30
degrees C.
Because of something called the "boundary layer" the velocity profile
will be faster in the center of your tunnel than at the walls. It
will resemble something like a U shape for higher Reynolds numbers and
for very low Reynolds numbers may look more like a parabola. Reynolds
number is computed by:
Re=rho*V*L/mu
where rho is the air density, V is the flow velocity, and mu is a
property called the kinematic viscosity which is a function of
temperature.
The Reynolds number, like the Mach number, the Nusselt number, and a
few other fluid dynamics properties is a dimensionless ratio. Flows
with a similar dimensionless property should behave more or less the
same. This is called similitude.
Mass flow calculations first require that you know the air speed
profile of your tunnel and then you will need to compute the density
of the air in the tunnel and then perform an integration process to
calculate the actual mass flow through a particular plane of interest
in the tunnel.
Also, even when you put a test probe into the tunnel to measure the
flow in the tunnel, this will interfere with the free flow to a
certain of the tunnel. To minimize this, the test probes have to be
carefully designed and their size needs to be much smaller than the
overall tunnel dimensions. Later when you put a test model in the
tunnel, it and it's mounting system will also have an interference
effect on the tunnel that has to be accounted for.
To give a simple (perhaps an overly simple) answer to your question,
temperature and barometric pressure will play into your problems of
computing forces in that they affect the density of the fluid medium
in your tunnel via the unified gas law (which is a combined expression
of Charles and Boyles laws for perfect gases):
PV=nRT
or
Pv=rT
where rho, the density is the inverse of v, so this is sometimes
written as:
P/rho=rT
This only applies for perfect gases though. A perfect gas is one
where the constant pressure and constant volume specific heats (Cv,
and Cp) are fixed. The hotter and more dense the fluid medium, the
less true these equations become.
Temperature in these equations doesn't mean the common ways that we
ordinarily talk about temperature when cooking or talking about the
weather. Instead of C or F, temperature in the gas law must be on an
absolute scale such as Kelvin or Rankin. 0 degrees Kelvin or
Rankine=-273.15 degrees C or -459.67 degrees F. One Kelvin degree=1.8
Rankine degrees but both start at the same point of absolute zero.
For standard atmospheric conditions (called STP for standard
temperature and pressure), 1 cubic meter of air weighs about 1.226 kg.
You have to calculate the density of air at non standard conditions
by solving algebraically for the above gas law equation.
r is called the gas constant and can be derived from the universal gas
constant R (8314 units I can't remember of the top of my head but it
involves kJ/kg.mole or something like) by deviding by the molecular
weight of the gas in question. If the gas is a mixture then you will
have to apply the partial pressures rule to come up with an averaged
molecular weight of the mixture. Dry air contains mostly nitrogen
which has an atomic weight of 28 (about 79%), and then oxygen (about
20%) which has an atomic weight of 32, and the balance (about 1%)of
inert gases (Helium, argon, krypton, etc.) which have much smaller
atomic weights. For dry air r (small r that is) is about 287.
If the air is not dry, then you have to account for the water vapor in
the air by figuring out what partial pressure of water vapor is in the
air and then performing an average between the water vapor portion and
the other components of the air. Wator vapor only has a molecular
weight of 18 (1 Oxygen + 2 Hydrogens=18) and so is lighter than dry
air and tends to make the air less dense.
The partial pressure of water vapor that can be supported in the air
is a function of temperature that more or less grows exponentially
with temperature. I'm sure if you search the web you can find several
empirical equations for this. Relative Humidity (RH) is an expression
of how much water vapor is in an air sample versus the maximum that
can be supported at the current temperature of the air sample but what
you really want is the partial pressure of water vapor in the air.
There are sensors that can give this to you by measuring the
electrical conductivity of the air. Dry air is actually a very good
insulator, whereas water vapor decreases the insulating property of
the air.
All other things remaining equal, increasing the humidity will
decrease the density of the air.
All other things remaining equal, increasing the temperature will
result in decreasing density while decreasing temperature will result
in increasing density. If the temperature in your tunnel is different
than standard then you will need to account for this.
Tunnels generally heat up the air by the way when they accelerate the
air through the fan and also through boundary layer friction with the
tunnel walls. Many tunnels actually have heat exchangers to keep the
air from getting too hot. You will need to make sure you measure the
temperature at the same point thats you are measuring the static and
stagnation pressures in your your tunnel so that you can account for
its effects. Standard temperature is 15 degrees C or 59 degrees F.
For conversion purposes, 15 degrees Celsius =288.15 degrees Kelvin= 59
degrees Fahrenheit=518.6 degrees Rankine.
All other things remaining equal, increasing pressure will result in
increasing density, while decreasing pressure will result in
decreasing density. Barometric pressure is usually given by the
weather service as inches or millimeters of mercury or sometimes
millibars. For conversion purposes, 29.92
inHg=760mmHg=1000millibars=14.7 psi= 101325 Pascals pressure. If the
pressure in your tunnel is different than standard then you will need
to account for this.
Depending on tunnel velocity, you will also have to consider
stagnation versus static properties. Stagnation properties are what
you measure if you bring the flow at a point to a complete stop, i.e.
the kinetic (as opposed to random thermal) energy in the sample is
completely converted thermal energy. How you do this depends on what
speed of sample you are trying to measure and is the subject of whole
books. Suffice it to say that at low speeds there is little
difference between stagnation and static properties but the faster you
go, the less resemblance they bear to one another.
Compressibility is another issue. At low speeds air is
incompressible, but at higher speeds v>100m/sec, compressibility
becomes worth accounting for in your measurments.
At higher temperatures and velocities, (high supersonic, or
hypersonic, or high temperature >500 degrees C), the constant pressure
and constant volume (Cp and Cv) specific heat assumptions break down
and so does the gas law. The simplifications that can be made for
using the ratio of Cp/Cv (called gamma) also break down because Cp and
Cv and therefore gamma all stop being constants. Solving flow
problems in this regime becomes much more complex requiring numerical
models for Cp and Cv and requiring numerical (as opposed to simple
analytical) methods to compute flow properties.
Once you know the flow density, you can calculate air speed. For
lower speed low temperature tunnels (low subsonic) you can use a
simple incompressible Bernoulli equation for converting pitot-static
pressure to air speed. At higher speeds and temperatures this depends
on the regime (transonic, supersonic, hypersonic, etc.)
The Bernoulli equation is simply:
Pstagnation=Pstatic+1/2 rho * velocity^2
For lower speed supersonic, the isentropic gas relations are sometimes
used.
In any event, you have to be sure to get your units right. If you use
metric, pressure is Pascals (Newtons/m^2), rho is kg/m^3 and velocity
is meters/sec. It's harder in U.S/U.K units because of conversions
between slugs and pounds etc.
Also you have to consider the concept that there will be a steady
state average that you will measure and a transient/turbulent portion
that will occur for each parameter that you measure (temperature,
pressure, RH, etc.) that you will need to account for.
Once you know the air speed and the density, you can compute their
product - mass flow. Mass flow then can be used for other purposes
such as calculating performance properties if you are testing a jet
engine or propeller or something.
Hot wire anenometers work by heating a wire and measuring the
resistance of the wire. The faster the air flow past the wire
filament, the more it will cool. I don't remember the equations off
of the top of my head but I believe that there is a square rule
involved. Hot wires work better at lower speeds than pitot-static
sensors but both become less effective the slower you go.
LDV's are neat, high tech toys that I haven't had a chance to work
with yet but they measure the airspeed by measuring the doppler shift
in the light emitted by a laser beam going through the flow, much like
doppler (WX-88) weather radar works. They actually measure the speed
of the air more directly than the pitot-static or hot wire methods are
probably simpler to implement from an equations point of view but they
are very very expensive.
In conclusion, I know I have written a lot of stuff up here that
probably sounds pretty intimidating with regards to solving your
problem. It would help to eliminate some of this by telling us more
about your test problem so that we can make the appropriate
simplifying assumptions. Tell us more about the details.
Douglas De Clue
LabVIEW developer (and degreed Georgia Tech aerospace engineer)
[email protected]
Devont wrote in message news:<50650000000800000025530000-1027480788000@exchange.ni.com>...
> The problem is this: I'm setting up an airflow resistance test and I
> need to account for temperature and barometric pressure. However, I
> don't know how to setup LabVIEW to account for these variables. -
Adobe Bridge CS6 (Mac) won't open .arw files from my Sony RX100. I was told to update Camera Raw to at least 7.2. I tried to download this but got a DNG Converter instead. Where is Camera Raw? (it does not show up in a search of my hard drive. There is a folder of camera profiles but no extension or plug-in with this name). How do I find out what version I have already? How do I get the correct version? . . . OR . . . is it the case that Bridge will never open Sony raw files directly and I will have to do a separate conversion process every time I want to use a raw file??. Can someone explain this?
Thanks.A Good samaritan answered this for me on another forum
How to update Camera Raw -
I can not boot my MacBook Pro running on Lion 10.7.4. I pressed control, comment P and R keys and O got to the disk utility, then I tried to repair disk and it can not be repaired. I get a message that tells me to back up as much data as possible ?. But if I can not open the computer how can I save my data??
I have a back up until 2 weeks ago on time machine. but the work of the last 2 weeks is extremely important how can I get it??
If I use m time machine backup do I loose the additional data of the last two weeks!,
Please help.. It's a huge amount of work that I have done and can not loose itIf it were me, I'd get a new hard drive or SSD and put it in an external enclosure. Boot into the recovery partition, format the new drive (not the old one) and install the OS to it. Shut down the Mac, open it up, and swap the drives. You may be able to read your data from the old one externally if you're lucky. If you're very lucky you may be able to use Migration Assistant to move all your stuff to the new drive.
Look at ifixit.com for the exact procedure to get to the drive on your model. If it's a unibody it's pretty simple.
http://www.amazon.com/Sabrent-2-5-Inch-Aluminum-Enclosure-EC-TB4P/dp/B005EIGUD4/ ref=sr_1_3?ie=UTF8&qid=1392154588&sr=8-3&keywords=2.5+enclosure -
? How can I get and keep the sound on my ipad?
I keep losing the sound on my ipad. Help.
Try this - Reset the iPad by holding down on the Sleep and Home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons. (This is equivalent to rebooting your computer.)
Check your settings. The iPads have a small switch on the right edge. It can be used as a rotation lock to keep the screen from automatically reorienting itself as you move around, but you need to have the tablet’s settings configured properly. That same switch, right above the volume buttons, can also be set to function instead as a mute button to silence certain types of audio.
If the switch is set to work as a mute button, you can change its purpose to “screen-rotation lock” by tapping the Settings icon on the home screen. On the Settings screen, tap General on the left side, and on the right side of the screen flick down to “Use Side Switch to.” Tap to select Lock Rotation or Mute to set the button’s function. Even if you set the side switch for your preferred use, you can still mute the Mini or lock the screen. Just double-click the Home button, and when the panel of apps appears along the bottom edge of the screen, flick the row from left to right with your finger. Tap the icon on the far left side of the row to either lock the iPad’s screen or mute the iPad’s alerts, notifications and sound effects. Music, podcasts and video are not muted unless you turn the volume all the way down.
iPhone: Can't hear through the receiver or speakers
http://support.apple.com/kb/ts1630
http://www.atreks.com/app-no-sound-on-ipad-4-%E2%80%93-what-to-do/
To solve some sound problems, just follow these simple steps
1. Go to Settings
2. Tap on General
3. Tap on Reset
4. Tap on Reset All Settings
Cheers, Tom -
How can I get and change the values of Withholding tax grid in MIRO trx
Hi everyone,
I have a requirement where I need to get and change WT_WITHCD field in MIRO's Withholding tax grid. Is there a function module / Badi to do this? I used MRM_HEADER_CHECK, but the parameters related with this badi doesn't have this value.
Do you have any idea?
Thanks in advance!
Regards.
Leo.Hello Leonardo,
You can change that table with help of the filed-symbol in the BADI MRM_HEADER_CHECK.
LOOP AT ti_drseg INTO ls_drseg.
lv_index = sy-tabix.
LS_DRSEG-MWSKZ = 'I0' . " < For example
MODIFY ti_drseg FROM ls_drseg INDEX lv_index.
ENDLOOP.
FIELD-SYMBOLS: <drseg> TYPE mmcr_tdrseg.
ASSIGN ('(SAPLMR1M)ydrseg[]') TO <drseg>.
<drseg> = ti_drseg[]. " this will modify the data in MIRO with your modified data
Regards,
Naimesh Patel -
I have a new Intex Cloud Fx phone. In this, I go to 'Device in formation' and try to update the device by pressing update now, I get an error message that says 'an error occurred while checking for updates'. Also, it does not respond to the' last updated' command. When I press 'more device information' I can see’ OS version Intex_Cloud_FX_V07’. I have tried all kinds of procedures suggested on the net and elsewhere but have not succeeded in updating my phone, so far. This includes resetting the phone. I am using a Wi-fi connection. It seems that quite a few persons are facing this problem. There have been suggestions ranging from 'there is a bug' to 'there are no updates'. So, the problem persists, with no end in sight. I feel Mozilla should look at it.
Hi!
Thanks for contacting us today! I understand you are having issues with updating, and using the device.
I believe that we are aware of the update issue however, it is ultimately the carrier/ manufacturer to provide updates. Please contact the respective company for assistance.
As for device using, and things not working. Please provide us with more details. (Note: the bug may have already been fixed, but is available in a later update).
Thanks! -
Getting and setting dynamic y-field for flex chart
I'm pulling data from a amfphp service for
a series of charts. My client now wants the the chart's fields to be label and display data dynamically so they can change the service with out breaking the charts.
For example {Month:"January", Flex:39, Flash:71.8, Photoshop:23.7},
They'd like to be able to change the software names and the charts would still work without having to go into the code and change the yfield property.
A code sample would be great. Thanks in advance.You can declare a bindable string variable that you can use as title in your axis:
[Bindable]
private var labelForAxis:String="";
<mx:verticalAxis>
<mx:LinearAxis baseAtZero="false" title="{labelForAxis}" />
</mx:verticalAxis>
Every time you change the string variable you label will also change. -
How do I change and set the width of the Address and Search box
Currently, the Address box crowds out the Search. I really don't need the Address box as much as I need the Search box. I recall a method of setting them using a routine in the Chrome folder but I sure can't find it. Can you help?
Thank
EdMethod 1:<br/>
Using the resizer on the interface. See - https://support.mozilla.org/en-US/kb/search-bar-easily-choose-your-search-engine#w_moving-or-removing-the-search-bar (''second bullet item; done without entering customize mode.'' By default, Location and Search bars will occupy all available space on the Navigation toolbar in a 2 to 1 ratio, respectively.)
Method 2:<br/>
Add code to userChrome.css below the @namespace line.
''@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); /* only needed once */
See - http://kb.mozillazine.org/Editing_configuration#How_to_edit_configuration_files<br/>
Adjust the width to your needs, no space before px
*urlbar-container {max-width: 400px !important;}
*search-container {max-width: 200px !important;} -
How do I get to set the new three security questions so I can buy an album on ITUNES
I tried to by an album on itunes and it asked for three security question, none of which I have answered before and there is no reference as to where to answer these questions. Also the question have nothing to do with me or how I live my life and now way to amened these questions.
I tried to by an album on itunes and it asked for three security question, none of which I have answered before and there is no reference as to where to answer these questions. Also the question have nothing to do with me or how I live my life and now way to amened these questions.
Maybe you are looking for
-
How to fetch the current stock of material based on Plant?
Hi Experts, Could any one tell how do i need to get the current stock data of the material based on Plant. Thanks in advance. Regards, Abdur Rafique
-
Problems with integracao of the JDeveloper with Software Configuration Management (S
1) Error with JDeveloper 9i and Software Configutarion Management (SCM) I have a problem with the JDeveloper 9i integrated with the repositorio 6i (SCM). When I make checkout of a source in java of the repositorio, after that I make the alteration an
-
Lost Song, Now what do I do?
I have downloaded a song and I have deauthorized the music. Now what my brother did was delete it but one music was missing the original file. I went into search and searched for the orignal file and it didnt show up! Now what can I do to get it back
-
GRC 5.3 sp9, in CUP when creating a new request, if a company is selected on the main screen, when you search for roles, it comes back "no roles found". If you remove the company selection, then the roles show up. What could cause this?
-
GY-HM700E JVC .mov doesn`t open in pp CS5
Hi, what is wrong or what codec I need to open those .mov video clips in Premiere CS5. I have Quicktime installed and I`m using windows 7 64bit. Please help I just upgrade CS4 to CS5 because I thought that it can handel everything. Thank you.