components/visual-panels/core/src/java/smf-old/com/oracle/solaris/scf/common/ScfException.java
equal
deleted
inserted
replaced
18 * |
18 * |
19 * CDDL HEADER END |
19 * CDDL HEADER END |
20 */ |
20 */ |
21 |
21 |
22 /* |
22 /* |
23 * Copyright (c) 2009, 2012, Oracle and/or its affiliates. All rights reserved. |
23 * Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved. |
24 */ |
24 */ |
25 |
25 |
26 package com.oracle.solaris.scf.common; |
26 package com.oracle.solaris.scf.common; |
27 |
27 |
28 import com.oracle.solaris.rad.ObjectException; |
28 import com.oracle.solaris.rad.client.RadObjectException; |
29 import com.oracle.solaris.vp.panel.common.api.smf_old.SmfError; |
29 import com.oracle.solaris.vp.panel.common.api.smf_old.SmfError; |
30 import com.oracle.solaris.vp.panel.common.api.smf_old.SmfErrorCode; |
30 import com.oracle.solaris.vp.panel.common.api.smf_old.SmfErrorCode; |
31 |
31 |
32 /** |
32 /** |
33 * The SCF checked exeption class. |
33 * The SCF checked exeption class. |
38 public class ScfException extends Exception |
38 public class ScfException extends Exception |
39 { |
39 { |
40 private SmfErrorCode error_ = null; |
40 private SmfErrorCode error_ = null; |
41 private String msg_ = ""; |
41 private String msg_ = ""; |
42 |
42 |
43 public ScfException(ObjectException e) |
43 public ScfException(RadObjectException e) |
44 { |
44 { |
45 super(e); |
45 super(e); |
46 SmfError se = e.getPayload(SmfError.class); |
46 SmfError se = (SmfError)e.getPayload(); |
47 if (se != null) { |
47 if (se != null) { |
48 error_ = se.getError(); |
48 error_ = se.getError(); |
49 msg_ = se.getMessage(); |
49 msg_ = se.getMessage(); |
50 } else { |
50 } else { |
51 } |
51 } |