Equals of simpledateformat after perform format(..)
Hi,
i need help to understant the behaviour of the jdk in this code segment.
class TestEqual{
public static void main(String[] args)throws ParseException{
SimpleDateFormat simpleDateFormatInstance = new SimpleDateFormat("dd.MM.yyyy HH:mm:ss");
String sDate = "27.04.0099 12:34:56";
SimpleDateFormat clonedSimpleDateFormatInstance = (SimpleDateFormat)simpleDateFormatInstance.clone();
System.out.println(
simpleDateFormatInstance.equals(clonedSimpleDateFormatInstance)
); //returns True!
Date oDate = simpleDateFormatInstance.parse(sDate);
simpleDateFormatInstance.format(oDate);
System.out.println(
simpleDateFormatInstance.equals(clonedSimpleDateFormatInstance)
); //returns False!
after perform format(..) the both objects, simpleDateFormatInstance and clonedSimpleDateFormatInstance, are not equal any more.
thanks for help
mr.dje
They may be equivellent, but they are not equal. In other words:
myObject m = new myObject();
myObject n = new myOjbect();
are equivellent at the time of creation, but they are 2 different objects.
When you clone, you get a new object of the same type, seperate and distinct from each other, but having the same data content values.
if you say
myObject m = new myObject():
myOjbect n = m;
then they point to the same object, m == n because they are the same thing, but when you get a clone
myObject m = new myObject();
myOjbect n = m.clone();
then you have to seperate objects.
consider this:
public class myObject{
BufferedImage myImage = <some image>;
int i = 0}Now if this had a clone() method what would we want done?
myObject m = new myObject();
myObject n = m.clone();
If they were the same object and we did a m.myImage=null then n.myImage would become null--would we really want that? No, they are sperate and each contains values and subobjects which contain the same values, but retain their distinctness.
Similar Messages
-
Frame Crashes on Save Book After Performing Document Numbering Update
Frame 10 crashes every time when saving book after performing a Format\Document\Numbering update. All of sudden when performing a document "Update" Frame starting generating errors for specific documents in the book. Numbering in docuement does not match numbering for book. So I select those documents generating the error and then do a Format\Document\Numbering and just hit the set button. Then try to save the book and it crashes every time. It crashes for Format\Document\Numbering one document or all of them.
In Frame 7.1/Unix, it is commonly the case that an unrelated crash corrupts the Book's settings for Numbering, although it appears that nothing has changed. It is, of course, a nuisance to reset all the dialogs.
So what I do instead, and which you might try, is to set all of the book number dialogs (all six panes, for each component file) to "Read from File". That seems to be stable and survives crashes. It may or may not fix your problem. -
After performing a clean install on a stock apple 1TB fusion Hard Drive it appears as things got reversed and showing my startup as not using the SSD portion. The SSD portion of the fusion drive used to be on top in disk utility, now its on the bottom. It also appears that I have to many partitions. Im thinking i need to reformat my Hard Drive again. I can't seem to find any answers.
CoreStorage logical volume groups (1 found)
|
+-- Logical Volume Group C2619AFE-0EB5-4721-8C50-3F3DBA520D1B
=========================================================
Name: fusion
Status: Online
Size: 1120333979648 B (1.1 TB)
Free Space: 114688 B (114.7 KB)
|
+-< Physical Volume 583AAEA9-E333-4A83-9BE3-E937396E9248
| ----------------------------------------------------
| Index: 0
| Disk: disk0s2
| Status: Online
| Size: 120988852224 B (121.0 GB)
|
+-< Physical Volume B0C1CB16-D46F-4387-A679-B55392BB7934
| ----------------------------------------------------
| Index: 1
| Disk: disk1s2
| Status: Online
| Size: 999345127424 B (999.3 GB)
|
+-> Logical Volume Family FB42B9F4-CB77-4162-831B-7DCB7816E760
Encryption Status: Unlocked
Encryption Type: None
Conversion Status: NoConversion
Conversion Direction: -none-
Has Encrypted Extents: No
Fully Secure: No
Passphrase Required: No
|
+-> Logical Volume C0B8479B-C51C-45BF-B59B-1AA5DF3A3B83
Disk: disk2
Status: Online
Size (Total): 1111826497536 B (1.1 TB)
Conversion Progress: -none-
Revertible: No
LV Name: Fusion
Volume Name: Fusion
Content Hint: Apple_HFS
/dev/disk0
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *121.3 GB disk0
1: EFI EFI 209.7 MB disk0s1
2: Apple_CoreStorage 121.0 GB disk0s2
3: Apple_Boot Boot OS X 134.2 MB disk0s3
/dev/disk1
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *1.0 TB disk1
1: EFI EFI 209.7 MB disk1s1
2: Apple_CoreStorage 999.3 GB disk1s2
3: Apple_Boot Boot OS X 650.0 MB disk1s3
/dev/disk2
#: TYPE NAME SIZE IDENTIFIER
0: Apple_HFS Fusion *1.1 TB disk2Hi,
According to your descriptioin, I don't think this is system problem, it should be Intel driver problem. It would be contact Intel to confirm this issue whether this is their driver problem.
Roger Lu
TechNet Community Support -
Problem after Performing Leaving action related to OM
<b>Scenario:</b>
Hi this is the first time i am working in a an SAP HR environment where all most all components like OM,PA,Payroll,Time,PD etc is implemented in <b>4.6 Version.</b>
I had seen in the production server that after performing the Leaving action of the employee his/her Postion will change to 999999(Default postion) when we view InfoType 0001 0r 0000.
But in case of 1 employee it did not change to 999999 after leaving action was performed.It still shows the Position what he held when he was Active.
<b>Qn 1</b>.In the above case which is right?
<b>Qn.2</b> what should ideally happen in Standard SAP system in such case.
<b>Q3.</b> Can we change that postion to 99999 (default) of an employee whose status in Withdrawn?
<b>Qn.4</b>. Anyoption other than rehiring and terminating him to sove this?(is this option itself is right practise?)
<b>TIP: I dont know if the end user properly followed the steps in doing the Leaving Action</b>Hi Abhilash,
If you are getting the default position then the Integration plogi - preli is set to 99999999. and you should get it for all the termination action. Check with the user if she had run the leaver action as per your infogroup (in case her user profile is not set up)
Ideally thats the way it is set up as we dont need a position for a Terminated employee, and that position can be filled up by someone else.
You can change it to 99999999 if all other positions are default as per your termination action.
Regards
Uday -
Document not auto cleared after performing FF67
Hi all,
firstly i would like to acknowledge that i'm using version 4.7.
after performing FF67, bank recon document generated in main bank & clearing bank GL accounts. But it is not auto clear in the clearing bank GL account. the treatment is as post GL account & manual clear.
after checking:-
1. trans type ABC using int. algorithm 15 - use assignment field to clear.
2. posting type in posting rule is 4 - clear debit GL account
in FF67 screen variant, assignment field entered the same as assignment value in clearing bank account. by right, the documents will clear off automatically.
anyone can assist what else that i miss out?
thanks in advance.hi..
we can perform manual clearing or F.13, but the pupose of having such posting rule and posting type is to minimize steps of clearing.
by right, once ff67 posted, the clearing bank gl account will get cleared. -
i bought freehand MX, But after re-format my pc, this freehand programme can no longer be use. pls help.
[ email address removed by forum host ]And what exactly is the problem? What system? you need to be a lot more specific.
Mylenium -
I'm installing windows 7 64-bit on my imac which I've done before but I get a message that the partition is GPT even after I format the bootcamp partition. I just upgraded my hard drive to a 3tb and I'm allocating 1tb for windows. How can I fix this?
No easy fix for a few reasons:
1) Bootcamp requires a hybrid MBR for the partition table. That is: both an MBR and a GPT partition table at the same time with the GPT one having all partitions and the MBR one having only the ones that are relevant, but at most 4 of them (including the protective partition and the Macintosh HD one). Which leads us to:
2) The MBR part of the hybrid partition table cannot work with 3TB hard drives. MBR is limited to 2TB.
I am working on a small EFI app that can boot Windows in EFI mode on a Mac and that would mean that you can go GPT only on your system. The progress of the app is slow due to the nature of EFI and for now requires that you do an unattended Windows install with slipstreamed graphics drivers, but we are adding VGA loading on top of EFI quite soon after the rest of the app stabilises. The status of the app is documented at:
Win7 x64 booting natively via EFI (no bios emulation)
Windows does actually successfully boot in EFI mode on most Macs (anything with a 64bit EFI should work), but does not have graphics support even if you load the driver due to the VGA pci registers not being set by the firmware. Furthermore, in Setup and Safe Mode, Windows uses VGA instead of GOP which is a failure by design since VGA is a BIOS standard and not really compatible without hacks with EFI. Other EFI implementations also add VGA compatibility at a high cost to the firmware complexity for the VGA cards available on the market that don't actually contain anything in their ROM except the VGA BIOS.
My recomendations:
1) Install on a second smaller hard-drive; or
2) Wait for the EFI app to come out officially and use that to boot Windows Vista SP1 x64 and Windows 7 x64 (RTM and SP1) in the native EFI mode.
3) Wait for Windows 8 which supports VGA-less booting acording to the AMD presentation at UEFI Plugfest. -
Trying to Install Windows 8.1 on my late 2013 21.5" iMac. After I Format the Bootcamp partition, Windows Setup tells me "Windows can't be installed to this disk because it is GPT partitioned." Huh?
You must use the Windows formatter to format your Windows partition NTFS. Please be sure you select the Windows partition otherwise you might end up formatting your OS X partition NTFS.
-
Re: How to restore data after HDD format?
hi, folks
I need your help to restore some important data that gone after hdd formatting.
I didn't make any backup that was my mistake.
Everyone's help is appreciated.
Thanks to all.Hi,
it's already late to say but it's always recommended to backup data on the external medias. First of all, don't touch your hard drive, I mean don't format/move partitions. Once, i had the same problem while creating acronis recovery zone on the hard drive. Something gone wrong and I lost some data that I wouldn't mind but I also had some files from webmoney system (its' virtual money that you can exchange for real one). I tried many programs like Ontrack.EasyRecovery.Professional and e.t.c. Only with Power.Data.Recovery software could restore it. note, it's not free but Google can help you -
Issue on Cisco Unity Connection after performing 'utils ntp restart'
Hello everybody.
There's a client with Cisco Unity Connection 8.5.1.10000-206. After doing a 'utils ntp restart', the following message showed up:
Communication is not functioning correctly between the servers in the Cisco Unity Connection cluster. To review server status for the cluster, go to the Tools > Cluster Management page of Cisco Unity Connection Serviceability.
The client states that there was no service for 5 minutes and wants to know if performing this task shoud be disruptive or not and if there is any official document from Cisco stating this.
See SrvConnUnity_1.jpg sent by the client after performing the ntp restart.
Right now the service is normal (see SrvConnUnity_2.jpg attached). The client also sent a 'utils ntp
status':
admin:utils ntp status
ntpd (pid 10899) is running...
remote refid st t when poll reach delay offset jitter
==============================================================================
*127.127.1.0 LOCAL(0) 10 l 16 64 377 0.000 0.000 0.002
synchronised to local net at stratum 11
time correct to within 12 ms
polling server every 64 s
Current time in UTC is : Fri Apr 26 16:01:23 UTC 2013
Current time in America/Argentina/Buenos_Aires is : Fri Apr 26 13:01:23 ART 2013
admin:
Could anybody help me with this? What steps should I take? Many thanks in advance.
Best,
PatricioHello Patricio,
On the command line guide you won't see any downtime requirements for the Unity Connection server:
Command Line Interface Reference Guide for Cisco Unified Communications Solutions Release 8.5(1)
http://www.cisco.com/en/US/docs/voice_ip_comm/cucm/cli_ref/8_5_1/cli_ref_851.html
Utils ntp restart
This command restarts the NTP service.
Command syntax
utils ntp restart
Parameters
None
Requirements
Command privilege level: 0
Allowed during upgrade: Yes
Also on the caveats i do not see any particular mention for this: (Caveats could be found applicable to CUC)
Release Notes for Cisco Unified Communications Manager Release 8.5(1)
http://www.cisco.com/en/US/docs/voice_ip_comm/cucm/rel_notes/8_5_1/cucm-rel_notes-851.html
Breaking up the output of the "utils ntp status" there are are two considerations:
admin:utils ntp status
ntpd (pid 10899) is running...
remote refid st t when poll reach delay offset jitter
==============================================================================
*127.127.1.0 LOCAL(0) 10 l 16 64 377 0.000 0.000 0.002
First, you are using the ip address 127.127.1.0 which is the referenced used for the local system clock, the asterisc means is the preferred option as there is no other IP available. This is not a good practice and not recommended.
Secondly the stratum is unreliable, meaning too high to reach or too low to be accepted by Unity Connection.
If you would happen to run 'utils diagnose test' you would have probably seen an output as the following example below:
admin:utils diagnose test
Log file: platform/log/diag1.log
Starting diagnostic test(s)
===========================
test - disk_space : Passed (available: 25680 MB, used: 7849 MB)
skip - disk_files : This module must be run directly and off hours
test - service_manager : Passed
test - tomcat : Passed
test - tomcat_deadlocks : Passed
test - tomcat_keystore : Passed
test - tomcat_connectors : Passed
test - tomcat_threads : Passed
test - tomcat_memory : Passed
test - tomcat_sessions : Passed
test - validate_network : Reverse DNS lookup missmatch
test - raid : Passed
test - system_info : Passed (Collected system information in diagnostic log)
test - ntp_reachability : Passed
test - ntp_clock_drift : Passed
test - ntp_stratum : Failed
The reference NTP server is a stratum 11 clock.
NTP servers with stratum 5 or worse clocks are deemed unreliable.
Please consider using an NTP server with better stratum level.
Please use OS Admin GUI to add/delete NTP servers.
skip - sdl_fragmentation : This module must be run directly and off hours
skip - sdi_fragmentation : This module must be run directly and off hours
test - ipv6_networking : Passed
And on the RTMT (Real Time Monitoring Tool) you would have seen a Critical event:
Condition:
The best external NTP server, , is stratum , which is unacceptably high. External NTP servers must be <= strata 8 and should be <= strata 5. NTP server strata can be verified using the CLI 'utils ntp status' command ('st' column). Try using different NTP servers.
Problem cause:
All specified external NTP server(s) have unacceptably high stratum values. Network issues exist or the designated servers have unreliable stratum values.
Information is self explanatory and therefore reassures the need of having a NTP different from the server itself.
By the snippet you sent we can know that it is the publisher server, as the Subscriber polls this information from the Publisher.
Installing the Operating System and Cisco Unity Connection 8.x
http://www.cisco.com/en/US/docs/voice_ip_comm/connection/8x/installation/guide/8xcucig020.html
"Cisco recommends that you use an external NTP server to ensure accurate system time on the publisher server. Ensure the external NTP server is stratum 9 or higher (meaning stratums 1-9). The subscriber server will get its time from the publisher server"
Documentation also reaffirms the need for that NTP to be accessible otherwise your system can be degraded. Some addtional information which would be interesting to know is:
- Why did they had to restart the NTP in the first place?
System Requirements for Cisco Unity Connection Release 8.x
http://www.cisco.com/en/US/docs/voice_ip_comm/connection/8x/requirements/8xcucsysreqs.html
"A network time protocol (NTP) server must be accessible to the Connection server"
On the Cisco Unity Connection Serviceability> Tools> CLuster Management screen shot you sent i see that the ports were "Not Available" and that the customer stated "there was no service for 5 minutes".
By no service did they mean that over the phone they heard a disconnected tone or a failsafe message?
Additionaly after the servers resolved from SBR the Subscriber never recovered entirely as it did not start the Conversation Manager service.
Bottom line if they are able to reproduce it then it would be worth a while checking with TAC
Best regards,
David Rojas Peck
Cisco TAC Support Engineer, Unity
Email: [email protected]
Mon, Wed, and Fri 12:00 pm to 9:00 pm ET, Tue and Thu 8:00 am to 5:00pm ET
Cisco Worldwide Contact link is below for further reference.
http://www.cisco.com/en/US/support/tsd_cisco_worldwide_contacts.html -
I am unable to re-install my CS4 after I formatted my laptop. Please advise.
I am unable to re-install my CS4 after I formatted my laptop. Please advise.
You can download CS4 from the following page and install it as long as you have a valid sewrial number for it.
http://helpx.adobe.com/creative-suite/kb/cs4-product-downloads.html -
After performing a routine software update this week, I am having problems with both of my email accounts. I am unable to "Reply" to any emails. Does anyone have a solution to this problem?
I am having the same problem also Thought it was my network and reset everything including Apple TV but still the problem is there . I assume now it is down to iOS 8 prior to that was perfect
-
How to re-install iLife 2011 in Mac OS X Mountain Lion unit after you formatted and reinstall OS X?
Sign into the App Store with your Apple ID, click on the Purchases icon in the toolbar, locate the three iLife apps and redownload them.
-
I've got a MacBook Pro 1TB HD, the drive was damaged (probably dropped) after I formatted the new drive I was able to get the OSi onto the drive and it's now up and running..But prior to removing the old HD I was able to run CloneZilla to map the drive. The problem I'm having is getting the files and documents back on the new HD.
I created a folder on the desk top and moved all the files and docs onto it, ( files / docs was originally burnt on a DVD ). I'm not sure A) how to open the specific files B) which files to extract C) Is it as simple as drag and drop...
Hope you're able to understand my problem and offer some suggestions, in advance thank you for your time and effort...Hi, Steve -
Yes, the CD-ROM drive must be jumpered as Master in order for it to be bootable.
Your G4 (PCI) should have two built-in IDE buses - one is usually assigned to the CD-ROM and Zip drives, and the other is used for hard drives. If you have the hard drive connected to the same bus as the one the CD-ROM is on, try switching the hard drive to the other bus.
Set the hard drive's jumpers as Master.
Exception - if the hard drive is a Western Digital, it may have a third position, Single, which must be used when the drive is the only device on the bus.
Note - Cable Select jumper settings will not work on a G4 (PCI).
Edit - -
Startup Manager, which is what booting with Option held down invokes, is not available on a G4 (PCI).
Article #106178 - Startup Manager: How to Select a Startup Volume
Firewire Target Disk Mode is limited on a G4 (PCI) - it can be the Host machine, but not the Target machine.
Article #58583 - Firewire Target Disk Mode
Relatedly, a G4 (PCI) can not boot to firewire drives, although it can use them for storage.
Article #58606 - FireWire Booting -
How can i download and install lightroom after having formatted the hard disk?
How can I download and install lightroom after having formatted the hard disk?
I have the number of the order.Lightroom - all versions
Windows
http://www.adobe.com/support/downloads/product.jsp?product=113&platform=Windows
Mac
http://www.adobe.com/support/downloads/product.jsp?product=113&platform=Macintosh
Maybe you are looking for
-
E71 Linux Information, likes, and dislikes
The E71 is a fairly cool phone, but it took me a little while to get things working well with Linux after upgrading from my Motorola v3xx. To avoid other people having to figure things out, here's my info, and later in this a list of likes and dislik
-
how to clean up propagation error? 1- Oracle version 9.2.0.1.0 2-I have three instance bd1, bd2, bd3 in different machines 3-The 3 instance can communicate between them via network. 4-I have setup succefully streams environnement bidirectionally betw
-
I had a problem where I had to remove all of my picture, movie, and music files from my computer and now that I've put what I moved back onto my computer, I went to sync my iPod and realized that all of my previously downloaded apps and music files a
-
When I open dng images into Camera Raw (Photoshop CS2) they appear out of sequence, for example: 001, 003,002, 004. What do I need to do to correct that? Thanks.
-
I was having connection troubles and like a twerp I selected File->New 802.1x Connection... in Internet Connect. This added an icon (next to VPN) on the Internet Connect toolbar and even though I have no configuration this machine (and only this mach