You can subscribe to this list here.
2005 |
Jan
|
Feb
(1) |
Mar
(45) |
Apr
(150) |
May
(145) |
Jun
(150) |
Jul
(79) |
Aug
(313) |
Sep
(160) |
Oct
(309) |
Nov
(115) |
Dec
(60) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(160) |
Feb
(144) |
Mar
(127) |
Apr
(48) |
May
(102) |
Jun
(54) |
Jul
(245) |
Aug
(94) |
Sep
(152) |
Oct
(162) |
Nov
(166) |
Dec
(740) |
2007 |
Jan
(752) |
Feb
(437) |
Mar
(328) |
Apr
(373) |
May
(569) |
Jun
(399) |
Jul
(369) |
Aug
(627) |
Sep
(100) |
Oct
(306) |
Nov
(166) |
Dec
(282) |
2008 |
Jan
(68) |
Feb
(145) |
Mar
(180) |
Apr
(160) |
May
(277) |
Jun
(229) |
Jul
(1188) |
Aug
(51) |
Sep
(97) |
Oct
(99) |
Nov
(95) |
Dec
(170) |
2009 |
Jan
(39) |
Feb
(73) |
Mar
(120) |
Apr
(121) |
May
(104) |
Jun
(262) |
Jul
(57) |
Aug
(171) |
Sep
(131) |
Oct
(88) |
Nov
(64) |
Dec
(83) |
2010 |
Jan
(55) |
Feb
(67) |
Mar
(124) |
Apr
(64) |
May
(130) |
Jun
(75) |
Jul
(164) |
Aug
(64) |
Sep
(44) |
Oct
(17) |
Nov
(43) |
Dec
(31) |
2011 |
Jan
(21) |
Feb
(10) |
Mar
(43) |
Apr
(46) |
May
(52) |
Jun
(71) |
Jul
(7) |
Aug
(16) |
Sep
(51) |
Oct
(14) |
Nov
(33) |
Dec
(15) |
2012 |
Jan
(12) |
Feb
(61) |
Mar
(129) |
Apr
(76) |
May
(70) |
Jun
(52) |
Jul
(29) |
Aug
(41) |
Sep
(32) |
Oct
(23) |
Nov
(38) |
Dec
(26) |
2013 |
Jan
(35) |
Feb
(37) |
Mar
(51) |
Apr
(15) |
May
(52) |
Jun
(15) |
Jul
(23) |
Aug
(21) |
Sep
(46) |
Oct
(69) |
Nov
(57) |
Dec
(26) |
2014 |
Jan
(5) |
Feb
(13) |
Mar
(17) |
Apr
(1) |
May
(5) |
Jun
|
Jul
(2) |
Aug
(2) |
Sep
(1) |
Oct
(16) |
Nov
(8) |
Dec
(4) |
2015 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
(4) |
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
From: Benjamin B. <bg...@us...> - 2005-06-02 16:21:39
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/utils In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28343/Plugin/com/ibm/ecute/utils Modified Files: Constants.java Log Message: ECUTE 2.1 beta 1c: Support of native qualifier changes in the edit qualifiers dialog (changes of a native qualifier results in a change in the model) Index: Constants.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/utils/Constants.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- Constants.java 1 Jun 2005 10:57:44 -0000 1.12 +++ Constants.java 2 Jun 2005 16:21:28 -0000 1.13 @@ -22,7 +22,7 @@ public class Constants { - public static final String pluginVersion="2.1 beta 1b"; + public static final String pluginVersion="2.1 beta 1c"; public static final String toolName="ECUTE"; public static final String qualifiersFileName="QualifiersList.txt"; |
From: Benjamin B. <bg...@us...> - 2005-06-02 16:21:39
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/dialogs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28343/Plugin/com/ibm/ecute/rsa/core/internal/dialogs Modified Files: EditQualifiersDialog.java Log Message: ECUTE 2.1 beta 1c: Support of native qualifier changes in the edit qualifiers dialog (changes of a native qualifier results in a change in the model) Index: EditQualifiersDialog.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/dialogs/EditQualifiersDialog.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- EditQualifiersDialog.java 31 May 2005 13:12:47 -0000 1.5 +++ EditQualifiersDialog.java 2 Jun 2005 16:21:28 -0000 1.6 @@ -61,6 +61,7 @@ import org.eclipse.uml2.PackageableElement; import org.eclipse.uml2.Parameter; import org.eclipse.uml2.ParameterDirectionKind; +import org.eclipse.uml2.PrimitiveType; import org.eclipse.uml2.Property; import org.eclipse.uml2.Stereotype; import org.eclipse.uml2.Type; @@ -127,7 +128,6 @@ Button parentButton; Button editButton; Button removeButton; -// Button defaultButton; Composite valLegendComposite; Button applyButton; Button undoButton; @@ -186,11 +186,10 @@ String[] deletedQualifiers; int deletedQualifiersIndex; - //undo variables -// QualifierValueObject lastValueObject; -// int lastIndex; -// String lastAction; - + // in and out qualifier mapping variables + QualifierValueObject inValueObject = null; + QualifierValueObject outValueObject = null; + boolean first_inout = true; public EditQualifiersDialog(Shell shell, NamedElement element, int index, QualifiersPropertySection qualSec) { super(shell); @@ -232,7 +231,7 @@ new MessageBox(Display.getCurrent().getActiveShell(), SWT.YES|SWT.NO| SWT.ICON_QUESTION); - messageBox.setText("Perform changes?"); + messageBox.setText("Apply marks?"); messageBox.setMessage("You have made changes in the qualifier definitions.\n" + "Do you want to perform these changes now?"); if(messageBox.open() == SWT.YES){ @@ -242,6 +241,9 @@ } } fillValueTable(element); + + } else if(folder.getSelectionIndex() == 1){ + performMarksQuestion(); } } @@ -277,6 +279,8 @@ inheritComboBox.setText("Inheritance"); inheritComboBox.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { + // perform changes? + performMarksQuestion(); // get selected class String selected = inheritComboBox.getText(); uml2Model = getModel(element); @@ -328,6 +332,8 @@ propertiesComboBox.setText("Properties"); propertiesComboBox.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { + // perform changes? + performMarksQuestion(); // get selected property String selected = propertiesComboBox.getText(); if(element instanceof Class){ @@ -346,6 +352,8 @@ methodsComboBox.setText("Methods"); methodsComboBox.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { + // perform changes? + performMarksQuestion(); // get selected method String selected = methodsComboBox.getText(); if(element instanceof Class){ @@ -364,6 +372,8 @@ rolesComboBox.setText("Roles"); rolesComboBox.addSelectionListener(new SelectionAdapter() { public void widgetSelected(SelectionEvent e) { + // perform changes? + performMarksQuestion(); // get selected method String selected = rolesComboBox.getText(); if(element instanceof AssociationClass){ @@ -393,6 +403,8 @@ public void widgetSelected(SelectionEvent selectionevent) { + // perform changes? + performMarksQuestion(); if(element instanceof Property){ Property property = (Property)element; if(property.getOwner() instanceof Class) @@ -816,6 +828,8 @@ } } } else { + // perform changes? + performMarksQuestion(); this.close(); } } @@ -828,6 +842,10 @@ TableItem tableitem = valueTable.getItem(ai); QualifierValueObject valueObject = (QualifierValueObject)valueTable.getItem(ai).getData(); QualifierValueObject oldValueObject = cloneQualifierValueObject(valueObject); + + if(valueObject.name.equalsIgnoreCase("In")||valueObject.name.equalsIgnoreCase("Out")){ + setInOutValueObjects(valueObject); + } Dialog dialog = new EditValueDialog(Display.getCurrent().getActiveShell(), valueObject); if (dialog.open() == 0) { @@ -878,6 +896,30 @@ } } + private void setInOutValueObjects(QualifierValueObject valueObject){ + + if(valueObject.name.equalsIgnoreCase("In")){ + outValueObject = (QualifierValueObject)valueTable.getItem(getTableIndex(valueTable,"Out")).getData(); + }else if(valueObject.name.equalsIgnoreCase("Out")){ + inValueObject = (QualifierValueObject)valueTable.getItem(getTableIndex(valueTable,"In")).getData(); + } + } + + private int getTableIndex(Table table, String item){ + + int index = -1; + + TableItem[] items = table.getItems(); + for(int i = 0; i < items.length; i++){ + TableItem tableItem = items[i]; + if(tableItem.getText().equalsIgnoreCase(item)){ + index = i; + break; + } + } + return index; + } + private void editDefinition() { Shell shell = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(); int ai = definitionTable.getSelectionIndex(); @@ -1337,6 +1379,21 @@ } } + // set new qualifier value + for(int j = 0; j < editedValuesIndex; j++){ + + if(name.equalsIgnoreCase(editedValues[j].name)){ + qualifierValue = editedValues[j].value; + } + } + + for(int j = 0; j < removedValuesIndex; j++){ + + if(name.equalsIgnoreCase(removedValues[j].name)){ + qualifierValue = removedValues[j].value; + } + } + String as[] = {name, qualifierValue, type, definedIn, inheritance, translatable}; tableitem.setText(as); tableitem.setData(new QualifierValueObject(name, qualifierValue, type, definedIn, inheritance, @@ -1356,7 +1413,6 @@ tableitem.setBackground(RED); } } - return i; } @@ -2377,6 +2433,47 @@ deleteRemovedValues(); } + private void performMarksQuestion(){ + + if(editedValuesIndex > 0 || removedValuesIndex > 0){ + MessageBox messageBox = + new MessageBox(Display.getCurrent().getActiveShell(), + SWT.YES|SWT.NO| + SWT.ICON_QUESTION); + messageBox.setText("Apply marks?"); + messageBox.setMessage("You have changed the qualifier values.\n\n" + + "If you want to perform these changes now then\n" + + "click YES. Clicking NO will reset your changes."); + + int returnResult = messageBox.open(); + + if(returnResult == SWT.YES){ + + performValuesChanges(); + + valueTable.removeAll(); + fillValueTable(element); + + valLegendComposite.setVisible(false); + applyButton.setEnabled(false); + undoButton.setEnabled(false); + } + + else if(returnResult == SWT.NO){ + + resetEditedValues(); + resetRemovedValues(); + + valueTable.removeAll(); + fillValueTable(element); + + valLegendComposite.setVisible(false); + applyButton.setEnabled(false); + undoButton.setEnabled(false); + } + } + } + private class QualifierDefinitionObject{ private String name; private String type; @@ -2554,7 +2651,7 @@ this.name.equalsIgnoreCase("Inout")|| this.name.equalsIgnoreCase("Min")|| this.name.equalsIgnoreCase("Max")|| - this.name.equalsIgnoreCase("Octectstring")|| + this.name.equalsIgnoreCase("Octetstring")|| this.name.equalsIgnoreCase("Static")|| this.name.equalsIgnoreCase("Write")|| this.name.equalsIgnoreCase("Description")|| @@ -2825,7 +2922,7 @@ } - public void mapQualifierToModel(Element element, String qualifierName, String newValue){ + private void mapQualifierToModel(Element element, String qualifierName, String newValue){ // DESCRIPTION if(qualifierName.equalsIgnoreCase("Description")){ @@ -2861,8 +2958,208 @@ element.setValue(appliedStereo, "Value", newValue); } } - } -/* + } + + // AGGREGATION, COMPOSITION + if(element instanceof AssociationClass){ + + EList ownedEnds = ((AssociationClass)element).getOwnedEnds(); + Property prop1 = (Property)ownedEnds.get(0); + Property prop2 = (Property)ownedEnds.get(1); + + if(qualifierName.equalsIgnoreCase("Aggregation")){ + if(newValue.equalsIgnoreCase("false")){ + prop1.setAggregation(AggregationKind.NONE_LITERAL); + prop2.setAggregation(AggregationKind.NONE_LITERAL); // just to be sure + } else { + prop1.setAggregation(AggregationKind.SHARED_LITERAL); + prop2.setAggregation(AggregationKind.NONE_LITERAL); // just to be sure + } + } else if(qualifierName.equalsIgnoreCase("Composition")){ + if(newValue.equalsIgnoreCase("false")){ + prop1.setAggregation(AggregationKind.SHARED_LITERAL); + prop2.setAggregation(AggregationKind.NONE_LITERAL); // just to be sure + } else { + prop1.setAggregation(AggregationKind.COMPOSITE_LITERAL); + prop2.setAggregation(AggregationKind.NONE_LITERAL); // just to be sure + } + } + + } + + // IN, OUT + if(element instanceof Parameter && first_inout && + (qualifierName.equalsIgnoreCase("In")||qualifierName.equalsIgnoreCase("Out"))){ + + String out = null; + String in = null; + Parameter parameter = (Parameter)element; + if(qualifierName.equalsIgnoreCase("In")){ + in = newValue; + out = outValueObject.value; + } else if(qualifierName.equalsIgnoreCase("Out")){ + in = inValueObject.value; + out = newValue; + } + + if(in.equalsIgnoreCase("true") && out.equalsIgnoreCase("false")){ + parameter.setDirection(ParameterDirectionKind.IN_LITERAL); + } else if(in.equalsIgnoreCase("true") && out.equalsIgnoreCase("true")){ + parameter.setDirection(ParameterDirectionKind.INOUT_LITERAL); + } else if(in.equalsIgnoreCase("false") && out.equalsIgnoreCase("true")){ + parameter.setDirection(ParameterDirectionKind.OUT_LITERAL); + } else if(in.equalsIgnoreCase("false") && out.equalsIgnoreCase("false")){ + parameter.setDirection(ParameterDirectionKind.IN_LITERAL); // "in" is default value in RSA + MessageBox messageBox = + new MessageBox(Display.getCurrent().getActiveShell(), + SWT.OK| + SWT.ICON_INFORMATION); + messageBox.setText("Invalid parameter direction"); + messageBox.setMessage("You have chosen an invalid parameter direction.\n\n" + + "You've set the \"in\" and \"out\" qualifiers to \"false\".\n" + + "In RSA/RSM each parameter has to have a direction.\n" + + "Since \"in\" is the default direction for a parameter in\n" + + "RSA/RSM, the \"in\" qualifier is set to \"true\" and the\n" + + "\"out\" qualifier is set to \"false\"."); + messageBox.open(); + } + } + + if(first_inout){ + first_inout = false; + } else { + first_inout = true; + } + + // MIN, MAX + if(element instanceof Property){ + if(qualifierName.equalsIgnoreCase("Min")){ + int min = new Integer(newValue).intValue(); + ((Property) element).setLowerBound(min); + } + if(qualifierName.equalsIgnoreCase("Max")){ + if(newValue.equalsIgnoreCase("null")){ + newValue = "-1"; + } + int max = new Integer(newValue).intValue(); + try { + ((Property) element).setUpperBound(max); + } catch (RuntimeException e) { + MessageBox messageBox = + new MessageBox(Display.getCurrent().getActiveShell(), + SWT.OK| + SWT.ICON_ERROR); + messageBox.setText("Illegal max value"); + messageBox.setMessage("You have chosen an invalid value for the \"max\" qualifier.\n\n" + + "The value of the \"max\" qualifier must be lower than the\n" + + "value of the \"min\" qualifier."); + messageBox.open(); + } + } + } + + //OCTETSTRING + if(qualifierName.equalsIgnoreCase("Octetstring")){ + if(newValue.equalsIgnoreCase("true")){ + uml2Model = getModel(element); + PrimitiveType octetstring = (PrimitiveType)uml2Model.getImportedMember("octetstring"); + if(element instanceof Property){ + Property prop = (Property)element; + prop.setType(octetstring); + } else if(element instanceof Operation){ + Operation op = (Operation)element; + Parameter returnType = op.getReturnResult("ReturnType"); + returnType.setType(octetstring); + } else if(element instanceof Parameter){ + Parameter param = (Parameter)element; + param.setType(octetstring); + } + } else if(newValue.equalsIgnoreCase("false")){ + + String elementString = ""; + + if(element instanceof Property){ + Property prop = (Property)element; + prop.setType(null); + elementString = "The type of this property is set to \"null\" now."; + } else if(element instanceof Operation){ + Operation op = (Operation)element; + Parameter returnType = op.getReturnResult("ReturnType"); + returnType.setType(null); + elementString = "The return type of this method is set to \"null\" now."; + } else if(element instanceof Parameter){ + Parameter param = (Parameter)element; + param.setType(null); + elementString = "The type of this parameter is set to \"null\" now."; + } + + MessageBox messageBox = + new MessageBox(Display.getCurrent().getActiveShell(), + SWT.OK| + SWT.ICON_INFORMATION); + messageBox.setText("\"Octetstring\" qualifier changed"); + messageBox.setMessage("You have set the value of the \"octetstring\" qualifier to false.\n\n" + + elementString); + messageBox.open(); + } + } + + // STATIC + if(qualifierName.equalsIgnoreCase("static")){ + if(newValue.equalsIgnoreCase("true")){ + if(element instanceof Property){ + ((Property)element).setIsStatic(true); + } else if(element instanceof Operation){ + ((Operation)element).setIsStatic(true); + } + } else if(newValue.equalsIgnoreCase("false")){ + if(element instanceof Property){ + ((Property)element).setIsStatic(false); + } else if(element instanceof Operation){ + ((Operation)element).setIsStatic(false); + } + } + } + + // WRITE + if(qualifierName.equalsIgnoreCase("write")){ + if(element instanceof Property){ + if(newValue.equalsIgnoreCase("true")){ + ((Property)element).setIsReadOnly(false); + } else if(newValue.equalsIgnoreCase("false")){ + ((Property)element).setIsReadOnly(true); + } + } + } + + // ABSTRACT + if(qualifierName.equalsIgnoreCase("abstract")){ + if(element instanceof Class){ + if(newValue.equalsIgnoreCase("true")){ + ((Class)element).setIsAbstract(true); + } else if(newValue.equalsIgnoreCase("false")){ + ((Class)element).setIsAbstract(false); + } + } + } + + // KEY + if(qualifierName.equalsIgnoreCase("key")){ + if(element instanceof Property){ + Property property = (Property)element; + Stereotype stereo = property.getAppliedStereotype("CIM::Key"); + if(stereo == null){ + stereo = property.getApplicableStereotype("CIM::Key"); + } + if(newValue.equalsIgnoreCase("false")){ + property.unapply(stereo); + } else if(newValue.equalsIgnoreCase("true")){ + property.apply(stereo); + } + } + } + + /* // OCL if(qualifierName.equalsIgnoreCase("OCL")){ if (element instanceof Class){ @@ -3305,11 +3602,26 @@ private void updateEditedValues(){ + QualifierValueObject maxObject = null; + for(int i = 0; i < editedValuesIndex; i++){ QualifierValueObject object = editedValues[i]; - editValue(object, false); + if(object.name.equalsIgnoreCase("Max")){ + // ensure that changes of the max qualifier are always + // performed after the min qualifier is changed + maxObject = object; + } else { + editValue(object, false); + } + } + + if(maxObject != null){ + editValue(maxObject, false); } + first_inout = true; + + resetEditedValues(); } @@ -3415,6 +3727,7 @@ private class EditValueDialog extends Dialog{ QualifierValueObject valueObject; + Label textLabel; Button nullButton; Button trueButton; Button falseButton; @@ -3446,6 +3759,7 @@ formdata.top = new FormAttachment(0,5); label.setLayoutData(formdata); label.setText("Set value for " + valueObject.name + " (" + valueObject.datatype + ")"); + textLabel = label; if(valueObject.datatype.equalsIgnoreCase("Boolean")){ @@ -3461,7 +3775,6 @@ if (nullB.getSelection() == true){ trueButton.setEnabled(false); falseButton.setEnabled(false); - //booleanValue = "null"; } else { trueButton.setEnabled(true); falseButton.setEnabled(true); @@ -3484,7 +3797,6 @@ { trueButton.setSelection(true); falseButton.setSelection(false); - //booleanValue = "true"; } }); this.trueButton = trueButton; @@ -3541,6 +3853,41 @@ trueButton.setEnabled(true); falseButton.setEnabled(true); } + + // check datatype + if(valueObject.name.equalsIgnoreCase("Association")){ + textLabel.setText("You can't change the value of the \"association\" qualifier !\n\n" + + "Changing this value would mean that you'd like to tranform a class\n" + + "to an association or the other way round and this is not allowed."); + nullButton.setEnabled(false); + trueButton.setEnabled(false); + falseButton.setEnabled(false); + + } else if(valueObject.name.equalsIgnoreCase("Aggregate")){ + textLabel.setText("You can't change the value of the \"aggregate\" qualifier !\n\n" + + "If you want to change the kind of the association, then use the\n" + + "\"aggregation\" and \"composition\" qualifiers of the parent class.\n" + + "\"Aggregate\" is set \"false\" when \"aggregation\" is set \"false\"\n" + + "and it is set \"true\" when \"aggregation\" is set \"true\".\n\n" + + "If you want to change the direction of the association then you\n" + + "have to delete it from the model and draw it the other way round."); + nullButton.setEnabled(false); + trueButton.setEnabled(false); + falseButton.setEnabled(false); + + } else if(valueObject.name.equalsIgnoreCase("Aggregation") || + valueObject.name.equalsIgnoreCase("Composition") || + valueObject.name.equalsIgnoreCase("In") || + valueObject.name.equalsIgnoreCase("Out") || + valueObject.name.equalsIgnoreCase("Octetstring") || + valueObject.name.equalsIgnoreCase("Static") || + valueObject.name.equalsIgnoreCase("Write") || + valueObject.name.equalsIgnoreCase("Abstract") || + valueObject.name.equalsIgnoreCase("Key") ){ + + nullButton.setEnabled(false); + } + } else { textFieldValue = valueObject.value; @@ -3589,6 +3936,8 @@ if(!valueObject.value.equalsIgnoreCase("null")){ textField.setText(valueObject.value); + int end = textField.getText().length(); + textField.setSelection(0, end); } else { textField.setText("(null)"); textField.setEnabled(false); @@ -3613,6 +3962,11 @@ } } }); + + if(valueObject.name.equalsIgnoreCase("Min")){ + + nullButton.setEnabled(false); + } } return label; @@ -3625,60 +3979,13 @@ } else { nullValue = false; } - - if(valueObject.datatype.equalsIgnoreCase("String")){ - // check datatype - if(valueObject.datatype.equalsIgnoreCase("sint8")| - valueObject.datatype.equalsIgnoreCase("uint8")){ - try { - Byte byte_ = new Byte(textFieldValue); - if(valueObject.datatype.equalsIgnoreCase("uint8") && byte_.compareTo(new Byte("0")) < 0 ){ - correctDatatype = false; - } - } catch (NumberFormatException e) { - correctDatatype = false; - } - } - - if(valueObject.datatype.equalsIgnoreCase("sint16")| - valueObject.datatype.equalsIgnoreCase("uint16")){ - try { - Short short_ = new Short(textFieldValue); - if(valueObject.datatype.equalsIgnoreCase("uint16") && short_.compareTo(new Short("0")) < 0 ){ - correctDatatype = false; - } - } catch (NumberFormatException e) { - correctDatatype = false; - } - } - - if(valueObject.datatype.equalsIgnoreCase("sint32")| - valueObject.datatype.equalsIgnoreCase("uint32")){ - try { - Integer integer_ = new Integer(textFieldValue); - if(valueObject.datatype.equalsIgnoreCase("uint32") && - integer_.compareTo(new Integer("0")) < 0 ){ - correctDatatype = false; - } - } catch (NumberFormatException e) { - correctDatatype = false; - } + + // check integer datatype + if(!valueObject.datatype.equalsIgnoreCase("boolean")){ + if(valueObject.datatype.indexOf("int") > -1){ + correctDatatype = isCorrectIntValue(valueObject); } - - if(valueObject.datatype.equalsIgnoreCase("sint64")| - valueObject.datatype.equalsIgnoreCase("uint64")){ - try { - Long long_ = new Long(textFieldValue); - if(valueObject.datatype.equalsIgnoreCase("uint64") && - long_.compareTo(new Long("0")) < 0 ){ - correctDatatype = false; - } - } catch (NumberFormatException e) { - correctDatatype = false; - } - } } - if(nullButton.getSelection() == true){ correctDatatype = true; } @@ -3692,9 +3999,9 @@ messageBox.setMessage("The value does not fit the qualifier's datatype!\n" + "The type of this value must be " + valueObject.datatype + "."); messageBox.open(); - correctDatatype = true; textField.setFocus(); - textField.setSelection(0); + int end = textField.getText().length(); + textField.setSelection(0, end); } else { if(valueObject.datatype.equalsIgnoreCase("boolean")){ if(nullButton.getSelection()){ @@ -3709,6 +4016,62 @@ } this.close(); } + + correctDatatype = true; + } + + private boolean isCorrectIntValue(QualifierValueObject valueObject){ + + boolean correctDatatype = true; + + if(valueObject.datatype.equalsIgnoreCase("sint8")| + valueObject.datatype.equalsIgnoreCase("uint8")){ + try { + Byte byte_ = new Byte(textFieldValue); + if(valueObject.datatype.equalsIgnoreCase("uint8") && byte_.compareTo(new Byte("0")) < 0 ){ + correctDatatype = false; + } + } catch (NumberFormatException e) { + correctDatatype = false; + } + } + else if(valueObject.datatype.equalsIgnoreCase("sint16")| + valueObject.datatype.equalsIgnoreCase("uint16")){ + try { + Short short_ = new Short(textFieldValue); + if(valueObject.datatype.equalsIgnoreCase("uint16") && short_.compareTo(new Short("0")) < 0 ){ + correctDatatype = false; + } + } catch (NumberFormatException e) { + correctDatatype = false; + } + } + else if(valueObject.datatype.equalsIgnoreCase("sint32")| + valueObject.datatype.equalsIgnoreCase("uint32")){ + try { + Integer integer_ = new Integer(textFieldValue); + if(valueObject.datatype.equalsIgnoreCase("uint32") && + integer_.compareTo(new Integer("0")) < 0 ){ + correctDatatype = false; + } + } catch (NumberFormatException e) { + correctDatatype = false; + } + } + else if(valueObject.datatype.equalsIgnoreCase("sint64")| + valueObject.datatype.equalsIgnoreCase("uint64")){ + try { + Long long_ = new Long(textFieldValue); + if(valueObject.datatype.equalsIgnoreCase("uint64") && + long_.compareTo(new Long("0")) < 0 ){ + correctDatatype = false; + } + } catch (NumberFormatException e) { + correctDatatype = false; + } + } + + return correctDatatype; } } |
From: Viktor M. <mih...@us...> - 2005-06-02 15:28:44
|
Update of /cvsroot/sblim/indication_helper In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31446 Modified Files: ind_helper.c Log Message: Added debug message for delivery failure. Index: ind_helper.c =================================================================== RCS file: /cvsroot/sblim/indication_helper/ind_helper.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- ind_helper.c 17 May 2005 17:20:22 -0000 1.8 +++ ind_helper.c 2 Jun 2005 15:28:35 -0000 1.9 @@ -923,6 +923,12 @@ { IND_HLP_DEBUG ("Indication delievered."); } + else + { + char mmsg[50]; + snprintf(mmsg,50,"Indication NOT delievered, rc=%d",status.rc); + IND_HLP_DEBUG (mmsg); + } break; /* Break out of the loop. That way we can do our job - delievering the indication based on the filter */ |
From: Benjamin B. <bg...@us...> - 2005-06-01 13:04:33
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19846/Plugin/com/ibm/ecute/rsa/ui/internal/wizards Modified Files: ExportCIMMOFWizard.java Log Message: added the ecute version information to the export CIM MOF wizard page Index: ExportCIMMOFWizard.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards/ExportCIMMOFWizard.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- ExportCIMMOFWizard.java 6 Dec 2004 17:17:40 -0000 1.3 +++ ExportCIMMOFWizard.java 1 Jun 2005 13:04:20 -0000 1.4 @@ -9,6 +9,7 @@ import org.eclipse.ui.IWorkbench; import com.ibm.ecute.EcuteEclipsePlugin; +import com.ibm.ecute.utils.Constants; import com.ibm.ecute.utils.License; import com.ibm.xtools.msl.core.internal.services.model.ApplicationConfiguration; @@ -30,7 +31,8 @@ private static final String MOF_EXTENSION = EcuteBundle.getResourceString("MOF.extension"); private static final String PAGE_DESCRIPTION = EcuteBundle.getResourceString("ExportMOF.description"); - private static final String PAGE_TITLE = EcuteBundle.getResourceString("ExportMOF.title"); + private static final String PAGE_TITLE = EcuteBundle.getResourceString("ExportMOF.title") + + " (" + Constants.toolName + " " + Constants.pluginVersion + ")"; private final String MODEL_EXTENSION = ApplicationConfiguration.getFileExtensionForType("Model"); private IStructuredSelection selection; |
From: Viktor M. <mih...@us...> - 2005-06-01 13:03:41
|
Update of /cvsroot/sblim/cmpi-network In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19277 Modified Files: configure.ac Log Message: Changed version number to 1.3.5. Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/cmpi-network/configure.ac,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- configure.ac 11 May 2005 11:42:02 -0000 1.3 +++ configure.ac 1 Jun 2005 13:03:32 -0000 1.4 @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.59) -AC_INIT(SBLIM BaseOS Network Providers, 1.3.4a, sbl...@li...,sblim-cmpi-network) +AC_INIT(SBLIM BaseOS Network Providers, 1.3.5, sbl...@li...,sblim-cmpi-network) AC_CONFIG_SRCDIR([OSBase_CommonNetwork.c]) AC_CONFIG_HEADER([config.h]) AM_INIT_AUTOMAKE |
From: Viktor M. <mih...@us...> - 2005-06-01 12:38:21
|
Update of /cvsroot/sblim/cmpi-fsvol In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7027 Modified Files: configure.ac Log Message: Updated version in configure.ac. Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/cmpi-fsvol/configure.ac,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- configure.ac 11 May 2005 12:04:26 -0000 1.4 +++ configure.ac 1 Jun 2005 12:38:08 -0000 1.5 @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.59) -AC_INIT(SBLIM BaseOS Filesystem Providers, 1.4.0a, sbl...@li...,sblim-cmpi-fsvol) +AC_INIT(SBLIM BaseOS Filesystem Providers, 1.4.1, sbl...@li...,sblim-cmpi-fsvol) AC_CONFIG_SRCDIR([OSBase_CommonFsvol.c]) AC_CONFIG_HEADER([config.h]) AM_INIT_AUTOMAKE |
From: Benjamin B. <bg...@us...> - 2005-06-01 12:37:41
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/plugins/output In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6940/Plugin/com/ibm/ecute/plugins/output Modified Files: CIMMOFOutputPlugin.java Log Message: ECUTE 2.1 beta 1b fixed directory problem caused by "\" on CIMMOF export in linux Index: CIMMOFOutputPlugin.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/plugins/output/CIMMOFOutputPlugin.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- CIMMOFOutputPlugin.java 21 Dec 2004 17:08:32 -0000 1.6 +++ CIMMOFOutputPlugin.java 1 Jun 2005 12:37:31 -0000 1.7 @@ -119,9 +119,6 @@ frame.addLine2Log("Generating CIM MOF"); frame.addLine2Log("***********************************************"); - - if((!path.endsWith("\\"))||path.endsWith("/")) - path+="\\"; generator = new mofCreator(path, true); buffer.createCompleteClasses(completeClasses); if(completeClasses){ |
From: Viktor M. <mih...@us...> - 2005-06-01 12:28:48
|
Update of /cvsroot/sblim/cmpi-fsvol In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv333 Modified Files: ChangeLog NEWS cmpiOSBase_BlockStorageStatisticalDataProvider.c Log Message: Bugs fixed: 1201380. InstanceId is checked for validity to avoid segfault. Index: NEWS =================================================================== RCS file: /cvsroot/sblim/cmpi-fsvol/NEWS,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- NEWS 12 May 2005 15:21:33 -0000 1.3 +++ NEWS 1 Jun 2005 12:28:35 -0000 1.4 @@ -5,3 +5,4 @@ - 1199129 Added toleration for newer (spec-conforming) CMPI headers. - 1199146 Added missing registration for BlockDeviceStatisticalData. - 1183805 Added support for OpenWBEM provider registration. +- 1201380 Fixed core dump in case of incorrect object path. Index: cmpiOSBase_BlockStorageStatisticalDataProvider.c =================================================================== RCS file: /cvsroot/sblim/cmpi-fsvol/cmpiOSBase_BlockStorageStatisticalDataProvider.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- cmpiOSBase_BlockStorageStatisticalDataProvider.c 20 Apr 2005 11:40:19 -0000 1.1 +++ cmpiOSBase_BlockStorageStatisticalDataProvider.c 1 Jun 2005 12:28:35 -0000 1.2 @@ -164,18 +164,21 @@ _OSBASE_TRACE(1,("--- %s CMPI GetInstance() called",_ClassName)); name = CMGetKey( cop, "InstanceID", &rc).value.string; - c_name = CMGetCharPtr(name); - + if (name) { + c_name = CMGetCharPtr(name); + } else { + c_name = ""; + } disk_id = strrchr(c_name,'_'); - disk_id += 1; - if (strlen(disk_id) <= 0) { + if (disk_id == NULL || strlen(disk_id+1) <= 0) { CMSetStatusWithChars( _broker, &rc, CMPI_RC_ERR_FAILED, "Could not get disk name." ); _OSBASE_TRACE(1,("--- %s CMPI GetInstance() failed for %s : %s",_ClassName,c_name,CMGetCharPtr(rc.msg))); return rc; } + disk_id += 1; cmdrc = get_disk_data(disk_id, &disk); if (cmdrc == 0 || disk == NULL) { Index: ChangeLog =================================================================== RCS file: /cvsroot/sblim/cmpi-fsvol/ChangeLog,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- ChangeLog 12 May 2005 15:21:33 -0000 1.5 +++ ChangeLog 1 Jun 2005 12:28:35 -0000 1.6 @@ -1,3 +1,9 @@ +2005-06-01 <mih...@dy...> + + * cmpiOSBase_BlockStorageStatisticalDataProvider.c: + Bug 1201380: check InstanceId key in getInstance to avoid + segfault. + 2005-05-12 <mih...@dy...> * provider-register.sh: Updated for OpenWBEM support. |
From: Viktor M. <mih...@us...> - 2005-06-01 12:28:48
|
Update of /cvsroot/sblim/cmpi-fsvol/mof In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv333/mof Modified Files: Linux_Fsvol.registration Log Message: Bugs fixed: 1201380. InstanceId is checked for validity to avoid segfault. Index: Linux_Fsvol.registration =================================================================== RCS file: /cvsroot/sblim/cmpi-fsvol/mof/Linux_Fsvol.registration,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Linux_Fsvol.registration 11 May 2005 12:04:27 -0000 1.2 +++ Linux_Fsvol.registration 1 Jun 2005 12:28:35 -0000 1.3 @@ -1,7 +1,7 @@ # Classname Namespace ProviderName ProviderModule ProviderTypes ... Linux_Ext2FileSystem root/cimv2 OSBase_LocalFileSystemProvider cmpiOSBase_LocalFileSystemProvider instance Linux_Ext3FileSystem root/cimv2 OSBase_LocalFileSystemProvider cmpiOSBase_LocalFileSystemProvider instance -Linux_ReiserFileSystem root/cimv2 OSBase_LocalFileSystemProvider cmpiOSBase_LocalFileSystemProvider instance +Linux_ReiserFileSystem root/cimv2 OSBase_LocalFileSystemProvider cmpiOSBase_LocalFileSystemProvider instance Linux_NFS root/cimv2 OSBase_NFSProvider cmpiOSBase_NFSProvider instance Linux_HostedFileSystem root/cimv2 OSBase_HostedFileSystemProvider cmpiOSBase_HostedFileSystemProvider instance association Linux_BootOSFromFS root/cimv2 OSBase_BootOSFromFSProvider cmpiOSBase_BootOSFromFSProvider instance association |
From: Benjamin B. <bg...@us...> - 2005-06-01 10:57:53
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/utils In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14312/Plugin/com/ibm/ecute/utils Modified Files: Constants.java Log Message: version name changed beta 1a -> beta 1b Index: Constants.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/utils/Constants.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- Constants.java 23 May 2005 07:16:30 -0000 1.11 +++ Constants.java 1 Jun 2005 10:57:44 -0000 1.12 @@ -22,7 +22,7 @@ public class Constants { - public static final String pluginVersion="2.1 beta 1a"; + public static final String pluginVersion="2.1 beta 1b"; public static final String toolName="ECUTE"; public static final String qualifiersFileName="QualifiersList.txt"; |
From: Viktor M. <mih...@us...> - 2005-06-01 10:57:15
|
Update of /cvsroot/sblim/wbemcli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13563 Modified Files: ChangeLog CimXml.cpp NEWS configure.ac Log Message: Bugs fixed: incorrect key type classification. Index: NEWS =================================================================== RCS file: /cvsroot/sblim/wbemcli/NEWS,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- NEWS 12 May 2005 09:05:17 -0000 1.3 +++ NEWS 1 Jun 2005 10:57:05 -0000 1.4 @@ -1,5 +1,10 @@ SBLIM WBEMCLI NEWS +Changes in Version 1.4.11 +========================= +Bugs: +- 1184528 Fix key type recognition. + Changes in Version 1.4.10 ========================= Bugs: Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/wbemcli/configure.ac,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- configure.ac 12 May 2005 09:05:17 -0000 1.9 +++ configure.ac 1 Jun 2005 10:57:05 -0000 1.10 @@ -1,7 +1,7 @@ # -*- Autoconf -*- # Process this file with autoconf to produce a configure script. -AC_INIT(SBLIM WBEMCLI, 1.4.10, sbl...@li...) +AC_INIT(SBLIM WBEMCLI, 1.4.10a, sbl...@li...) AC_CONFIG_SRCDIR([CimXml.cpp]) AC_CANONICAL_HOST Index: ChangeLog =================================================================== RCS file: /cvsroot/sblim/wbemcli/ChangeLog,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- ChangeLog 12 May 2005 09:05:17 -0000 1.3 +++ ChangeLog 1 Jun 2005 10:57:05 -0000 1.4 @@ -1,3 +1,10 @@ +2005-06-01 <mih...@dy...> + + * CimXml.cpp (toStringBuffer): + Bug 1184528: determine the type (string, numeric, boolean) + of key properties by the format of the value and generate + keybindings accordingly. + 2005-05-12 <mih...@dy...> * CimCurl.cpp: Index: CimXml.cpp =================================================================== RCS file: /cvsroot/sblim/wbemcli/CimXml.cpp,v retrieving revision 1.37 retrieving revision 1.38 diff -u -d -r1.37 -r1.38 --- CimXml.cpp 6 Dec 2004 17:08:47 -0000 1.37 +++ CimXml.cpp 1 Jun 2005 10:57:05 -0000 1.38 @@ -20,8 +20,6 @@ * Description: Line command interface to DMTF conforming WBEM servers */ -#define PEGASUS_CONFORM - #include "CimXml.h" #include <iostream> #include <cstdlib> @@ -1619,9 +1617,20 @@ name=string(n,p-n); p++; value=Option<ValueXml>(ValueXml(p)); - if (strcasecmp(p,"true")==0 || strcasecmp(p,"false")==0) type="boolean"; - else if (isdigit(*p)) type="numeric"; - else type="string"; + if (strcasecmp(p,"true")==0 || strcasecmp(p,"false")==0) { + type="boolean"; + } else if (*p=='+' || * p=='-' || isdigit(*p)) { + type="numeric"; + int i=1; + while (p[i]) { + if (!isdigit(p[i++])) { + type="string"; + break; + } + } + } else { + type="string"; + } } void PropertyXml::toStringBuffer(string &sb, char *q) @@ -2566,7 +2575,7 @@ } else { -#ifdef PEGASUS_CONFORM +#ifdef OLD_PEGASUS_CONFORM sb = sb + "<KEYVALUE VALUETYPE=\"" + "string" + "\">" + p.value.val().getValue() + "</KEYVALUE>"; #else sb = sb + "<KEYVALUE VALUETYPE=\"" + p.type + "\">" + p.value.val().getValue() + "</KEYVALUE>"; @@ -2584,7 +2593,7 @@ } else { sb = sb + "<KEYBINDING NAME=\"" + p.name + "\">"; -#ifdef PEGASUS_CONFORM +#ifdef OLD_PEGASUS_CONFORM sb = sb + "<KEYVALUE VALUETYPE=\"" + "string" + "\">" + p.value.val().getValue() + "</KEYVALUE>"; #else sb = sb + "<KEYVALUE VALUETYPE=\"" + p.type + "\">" + p.value.val().getValue() + "</KEYVALUE>"; |
From: yeechan <ibm...@us...> - 2005-05-31 19:30:46
|
Update of /cvsroot/sblim/cmpi-tests/cmpi-instancetest/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21413 Modified Files: TST_InstanceTest.c Log Message: #defect 1203799 Index: TST_InstanceTest.c =================================================================== RCS file: /cvsroot/sblim/cmpi-tests/cmpi-instancetest/src/TST_InstanceTest.c,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- TST_InstanceTest.c 31 May 2005 07:18:51 -0000 1.7 +++ TST_InstanceTest.c 31 May 2005 19:30:36 -0000 1.8 @@ -971,9 +971,10 @@ } /* Add the new instance to the end of the list */ - instances[sizeinstances] = newinstance; + instances[sizeinstances-1] = newinstance; + instances[sizeinstances] = NULL; sizeinstances++; - instances[sizeinstances] = NULL; /* Instances list is always NULL terminated */ +/* Instances list is always NULL terminated */ /* Finished */ exit: |
From: Benjamin B. <bg...@us...> - 2005-05-31 15:49:00
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv29496/Plugin/com/ibm/ecute/rsa/ui/internal/wizards Modified Files: ExportCIMMOFWizardPage.java ImportCIMMOFWizardPage.java Log Message: fixed directory problem caused by "\" on CIMMOF export in linux Index: ExportCIMMOFWizardPage.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards/ExportCIMMOFWizardPage.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- ExportCIMMOFWizardPage.java 14 Feb 2005 17:38:06 -0000 1.10 +++ ExportCIMMOFWizardPage.java 31 May 2005 15:48:50 -0000 1.11 @@ -671,9 +671,24 @@ } try { + String selectionPath = getSelectedDestinationPath(); + String osname = System.getProperty("os.name"); + System.out.println(osname); + // Windows system + if(osname.indexOf("win") > -1 || osname.indexOf("Win") > -1){ + if(!selectionPath.endsWith("\\")){ + selectionPath = selectionPath.concat("\\"); + } + System.out.println(selectionPath); + } else { // other system + if(!selectionPath.endsWith("/")){ + selectionPath = selectionPath.concat("/"); + } + System.out.println(selectionPath); + } PropertyList propertyList = new PropertyList(configFile, Constants.toolName); //Set configuration - propertyList.setProperty(Constants.cimMOFOutputPackageName, "Path", getSelectedDestinationPath()); + propertyList.setProperty(Constants.cimMOFOutputPackageName, "Path", selectionPath); propertyList.setProperty(Constants.cimMOFOutputPackageName, "CompleteClasses", fullClasses); propertyList.setProperty(Constants.rsaInputPackageName, "Model", modelDestination); propertyList.setProperty(Constants.rsaInputPackageName, "AllPackages", allPackages); @@ -694,8 +709,6 @@ e.printStackTrace(); } } - - } } Index: ImportCIMMOFWizardPage.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/ui/internal/wizards/ImportCIMMOFWizardPage.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- ImportCIMMOFWizardPage.java 8 Apr 2005 09:11:20 -0000 1.17 +++ ImportCIMMOFWizardPage.java 31 May 2005 15:48:50 -0000 1.18 @@ -927,7 +927,8 @@ modelName = modelName.substring(0 , modelName.lastIndexOf(FILE_EXT_DOT+FILE_EXT_MODEL)); } - modelDest = destinationPath.toOSString()+"\\" + modelName + ".emx"; + modelDest = destinationPath.toOSString() +"\\" + modelName + ".emx"; + System.out.println(modelDest); IProject newProject = null; if (newProjectRadio.getSelection()) { |
From: Benjamin B. <bg...@us...> - 2005-05-31 14:39:02
|
Update of /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27891/InstallShield55/ecute/Script Files Modified Files: Setup.dbg Setup.ins Setup.ino Setup.obs setup.rul Log Message: Changed the InstallShield script which caused a disk space error when ecute was installed on a machine without Rose being installed Index: Setup.ins =================================================================== RCS file: /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files/Setup.ins,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 Binary files /tmp/cvsc1iymB and /tmp/cvsWE7HVt differ Index: setup.rul =================================================================== RCS file: /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files/setup.rul,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- setup.rul 19 May 2005 13:52:08 -0000 1.4 +++ setup.rul 31 May 2005 14:38:50 -0000 1.5 @@ -514,7 +514,7 @@ // Check if Rose is installed RegDBSetDefaultRoot ( HKEY_LOCAL_MACHINE ); - CRMKEY="SOFTWARE\\Rational Software\\Rose"; + CRMKEY="SOFTWARE\\Rational Software\\Rose\\Rose"; if (RegDBKeyExist ( CRMKEY)=1) then RegDBGetKeyValueEx ( CRMKEY , "InstallDir" , rtype , svRoseDir , nvSize ); ComponentSetTarget (MEDIA, "<RoseDir>", svRoseDir+"\\framework\\frameworks"); @@ -916,3 +916,4 @@ + Index: Setup.obs =================================================================== RCS file: /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files/Setup.obs,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 Binary files /tmp/cvsTUfuPK and /tmp/cvsXsaTuD differ Index: Setup.ino =================================================================== RCS file: /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files/Setup.ino,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 Binary files /tmp/cvshq0qNN and /tmp/cvsibkJzG differ Index: Setup.dbg =================================================================== RCS file: /cvsroot/sblim/ecute/InstallShield55/ecute/Script Files/Setup.dbg,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 Binary files /tmp/cvsxsUNmZ and /tmp/cvs0IQHbS differ |
From: Viktor M. <mih...@us...> - 2005-05-31 14:28:36
|
Update of /cvsroot/sblim/cmpi-base In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20526 Modified Files: AUTHORS ChangeLog NEWS OSBase_OperatingSystem.c OSBase_UnixProcess.c README configure.ac Log Message: Bugs fixed: 1211913 UnixProcess data extraction and formatting. 1198184 implemented Ferenc Szalai's suggestion for release determination. Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/cmpi-base/configure.ac,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- configure.ac 11 May 2005 11:40:08 -0000 1.6 +++ configure.ac 31 May 2005 14:28:08 -0000 1.7 @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.59) -AC_INIT(SBLIM BaseOS Providers Base, 1.5.0a, sbl...@li...,sblim-cmpi-base) +AC_INIT(SBLIM BaseOS Providers Base, 1.5.1, sbl...@li...,sblim-cmpi-base) AC_CONFIG_SRCDIR([OSBase_Common.c]) AC_CONFIG_HEADER([config.h]) AM_INIT_AUTOMAKE Index: ChangeLog =================================================================== RCS file: /cvsroot/sblim/cmpi-base/ChangeLog,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- ChangeLog 12 May 2005 15:15:07 -0000 1.8 +++ ChangeLog 31 May 2005 14:28:08 -0000 1.9 @@ -1,3 +1,11 @@ +2005-05-31 <mih...@dy...> + + * OSBase_UnixProcess.c: + Bug 1211913: Fixed the UnixProcess field formatting problems. + Uses ps -p <pid> to retrieve single process data now. + Process name is determined using basename and brackets are stripped + from kernel daemons. + 2005-05-12 <mih...@dy...> * provider-register.sh: Updated for OpenWBEM support. Index: README =================================================================== RCS file: /cvsroot/sblim/cmpi-base/README,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- README 20 Apr 2005 11:34:56 -0000 1.12 +++ README 31 May 2005 14:28:08 -0000 1.13 @@ -110,8 +110,8 @@ Load Schema into CIMOM's repository ................................... -with Pegasus : -.............. +with Pegasus / OpenWBEM /sfcb : +............................... The loading and registering of the classes/associations and their provider is done during the "make postinstall". Index: NEWS =================================================================== RCS file: /cvsroot/sblim/cmpi-base/NEWS,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- NEWS 12 May 2005 15:15:07 -0000 1.4 +++ NEWS 31 May 2005 14:28:08 -0000 1.5 @@ -6,3 +6,4 @@ - 1199449 Fixed compile problem with new indication_helper 0.4.0 . - 1198184 Fixed release determination logic. - 1183805 Added support for OpenWBEM provider registration. +- 1211913 Fixed UnixProcess Name, State and Argument field scanning and formatting. Index: OSBase_OperatingSystem.c =================================================================== RCS file: /cvsroot/sblim/cmpi-base/OSBase_OperatingSystem.c,v retrieving revision 1.18 retrieving revision 1.19 diff -u -d -r1.18 -r1.19 --- OSBase_OperatingSystem.c 12 May 2005 15:15:07 -0000 1.18 +++ OSBase_OperatingSystem.c 31 May 2005 14:28:08 -0000 1.19 @@ -13,6 +13,7 @@ * Author: Heidi Neumann <hei...@de...> * Contributors: Viktor Mihajlovski <mih...@de...> * C. Eric Wu <cw...@us...> + * Ferenc Szalai <sz...@ei...> * * Description: * This shared library provides resource access functionality for the class @@ -125,6 +126,7 @@ char * get_os_distro() { char ** hdout = NULL; char * ptr = NULL; + char * cmd = NULL; int strl = 0; int i = 0; int rc = 0; @@ -133,25 +135,40 @@ _OSBASE_TRACE(4,("--- get_os_distro() called : init")); - rc = runcommand( "cat `find /etc/ -type f -maxdepth 1 -name *release* 2>/dev/null`" , NULL , &hdout , NULL ); - if( rc == 0 ) { - while ( hdout[i]) { - strl = strl+strlen(hdout[i])+1; - ptr = strchr(hdout[i], '\n'); + rc = runcommand( "find /etc/ -type f -maxdepth 1 -name *release* 2>/dev/null" , NULL , &hdout , NULL ); + if( rc == 0 && hdout != NULL && hdout[0] && strcmp (hdout[0], "") ) { + strl = strlen ("cat 2>/dev/null") + strlen (hdout[0]) + 1; + ptr = strchr(hdout[0], '\n'); + if (ptr) { *ptr = '\0'; + } + cmd = calloc (strl, sizeof(char)); + snprintf(cmd, strl, "cat %s 2>/dev/null", hdout[0]); + freeresultbuf(hdout); + hdout = NULL; + strl = 0; + rc = runcommand(cmd, NULL , &hdout , NULL ); + if( rc == 0 ) { + while ( hdout[i]) { + strl = strl+strlen(hdout[i])+1; + ptr = strchr(hdout[i], '\n'); + if (ptr) { + *ptr = '\0'; + } + i++; + } + i=0; + CIM_OS_DISTRO = calloc(1,strl); + strcpy( CIM_OS_DISTRO , hdout[0] ); i++; - } - i=0; - CIM_OS_DISTRO = calloc(1,strl); - strcpy( CIM_OS_DISTRO , hdout[0] ); - i++; - while ( hdout[i]) { - strcat( CIM_OS_DISTRO , " " ); - strcat( CIM_OS_DISTRO , hdout[i] ); - i++; + while ( hdout[i]) { + strcat( CIM_OS_DISTRO , " " ); + strcat( CIM_OS_DISTRO , hdout[i] ); + i++; + } } - } - else { + free (cmd); + } else { CIM_OS_DISTRO = calloc(1,6); strcpy( CIM_OS_DISTRO , "Linux" ); } Index: OSBase_UnixProcess.c =================================================================== RCS file: /cvsroot/sblim/cmpi-base/OSBase_UnixProcess.c,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- OSBase_UnixProcess.c 24 Jan 2005 12:05:52 -0000 1.11 +++ OSBase_UnixProcess.c 31 May 2005 14:28:08 -0000 1.12 @@ -30,6 +30,7 @@ #include <fcntl.h> #include <errno.h> #include <dirent.h> +#include <libgen.h> #include <sys/stat.h> #include <sys/wait.h> #include <sys/time.h> @@ -59,7 +60,7 @@ _OSBASE_TRACE(3,("--- enum_all_process() called")); - rc = runcommand( "ps --no-headers -eo pid,ppid,tty,pri,nice,uid,gid,pmem,pcpu,cputime,comm,session,state,args" , NULL, &hdout, NULL ); + rc = runcommand( "ps --no-headers -eo pid,ppid,tty,pri,nice,uid,gid,pmem,pcpu,cputime,session,state,args" , NULL, &hdout, NULL ); if( rc == 0 ) { lptrhelp = (struct processlist *)calloc(1,sizeof(struct processlist)); @@ -91,17 +92,10 @@ _OSBASE_TRACE(3,("--- get_process_data() called")); - cmd = (char*)malloc((strlen(pid)+7)); - strcpy(cmd, "/proc/"); - strcat(cmd, pid); - dpid=opendir(cmd); - if(cmd) free(cmd); - - if ( dpid != NULL ) { - cmd = (char*)malloc((strlen(pid)+95)); - strcpy(cmd, "ps --no-headers -eo pid,ppid,tty,pri,nice,uid,gid,pmem,pcpu,cputime,comm,session,state | grep "); - strcat(cmd, pid); + cmd = (char*)malloc((strlen(pid)+100)); + sprintf(cmd, "ps -p %s --no-headers -eo pid,ppid,tty,pri,nice,uid,gid,pmem,pcpu,cputime,session,state,args",pid); rc = runcommand( cmd , NULL, &hdout, NULL ); + if (rc == 0) { while( hdout[i] ) { if((ptr=strchr(hdout[i], '\n'))) { *ptr = '\0'; } str = hdout[i]; @@ -126,11 +120,9 @@ static int _process_data( char * phd , struct cim_process ** sptr ){ char ** parr = NULL; - char ** hdout = NULL; char * d = NULL; char * end = NULL; char * cmd = NULL; - char * ptr = NULL; FILE * fpstat = NULL; struct tm tmdate; unsigned long long kmtime = 0; // Kernel Mode Time @@ -170,8 +162,7 @@ (*sptr)->pmem = atoll(parr[7]); (*sptr)->pcpu = atol(parr[8]); - (*sptr)->pcmd = strdup(parr[10]); - (*sptr)->sid = atoll(parr[11]); + (*sptr)->sid = atoll(parr[10]); /* state of Linux processes : D uninterruptible sleep (usually IO) = Blocked (4) @@ -192,34 +183,19 @@ * 8 ... Stopped * 9 ... Growing */ - if(strcmp(parr[12],"R")==0) + if(strcmp(parr[11],"R")==0) (*sptr)->state = 3 ; - else if( strcmp(parr[12],"D")==0) + else if( strcmp(parr[11],"D")==0) (*sptr)->state = 4 ; - else if( strcmp(parr[12],"S")==0) + else if( strcmp(parr[11],"S")==0) (*sptr)->state = 6 ; - else if( strcmp(parr[12],"Z")==0) + else if( strcmp(parr[11],"Z")==0) (*sptr)->state = 7 ; - else if( strcmp(parr[12],"T")==0) + else if( strcmp(parr[11],"T")==0) (*sptr)->state = 8 ; /* values for array of Parameters */ - if( parr[13] == NULL ) { - cmd = (char*)malloc((strlen((*sptr)->pid)+28)); - memset(cmd, 0, (strlen((*sptr)->pid)+28)); - strcpy(cmd, "ps -p"); - strcat(cmd, (*sptr)->pid); - strcat(cmd, " --no-headers -o args"); - rc = runcommand( cmd, NULL, &hdout, NULL ); - if((ptr=strchr(hdout[0], '\n'))) { *ptr = '\0'; } - if( rc == 0 ) { - (*sptr)->args = line_to_array( hdout[0], ' ' ); - } - if(cmd) free(cmd); - freeresultbuf(hdout); - } - else { - i=13; + i=12; j=0; (*sptr)->args = calloc(100,sizeof(char*)); while(( parr[i] != NULL ) && (i < 100)) /* preventing buffer overflows */ { @@ -228,8 +204,12 @@ j++; i++; } + if (parr[12][0]=='[' && parr[12][strlen(parr[12])-1]==']') { + (*sptr)->pcmd = calloc(strlen(parr[12])-1,1); + strncpy((*sptr)->pcmd,parr[12]+1,strlen(parr[12])-2); + } else { + (*sptr)->pcmd = strdup(basename(parr[12])); } - freeresultbuf(parr); /* ModulePath */ @@ -288,7 +268,7 @@ buf = (char*)malloc(1024); memset(buf, 0, 1024); - rc = readlink(path, buf, sizeof(buf)); + rc = readlink(path, buf, 1024); if( rc == -1 ) { free(buf); buf = strdup(cmd); Index: AUTHORS =================================================================== RCS file: /cvsroot/sblim/cmpi-base/AUTHORS,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- AUTHORS 20 Apr 2005 11:34:55 -0000 1.2 +++ AUTHORS 31 May 2005 14:28:08 -0000 1.3 @@ -6,3 +6,6 @@ support for class Linux_OperatingSytemStatisticalData and the association Linux_OperatingSystemStatistics was done by Michael Schuele <sch...@de...> ... thx :) + +bugfix for release determination if no /etc/*release* file is found has +been suggested by Ferenc Szalai <sz...@ei...> |
From: Viktor M. <mih...@us...> - 2005-05-31 14:28:34
|
Update of /cvsroot/sblim/cmpi-base/test/system/linux In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20526/test/system/linux Modified Files: Linux_OperatingSystem.version.sh Log Message: Bugs fixed: 1211913 UnixProcess data extraction and formatting. 1198184 implemented Ferenc Szalai's suggestion for release determination. Index: Linux_OperatingSystem.version.sh =================================================================== RCS file: /cvsroot/sblim/cmpi-base/test/system/linux/Linux_OperatingSystem.version.sh,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Linux_OperatingSystem.version.sh 29 Mar 2004 15:36:31 -0000 1.1 +++ Linux_OperatingSystem.version.sh 31 May 2005 14:28:09 -0000 1.2 @@ -1,5 +1,5 @@ #!/bin/sh -files=`find /etc/ -name *release* 2>/dev/null`; +files=`find /etc/ -type f -maxdepth 1 -name *release* 2>/dev/null | head -1`; value=`cat $files`; -echo $value; \ No newline at end of file +echo $value; |
From: Viktor M. <mih...@us...> - 2005-05-31 14:13:26
|
Update of /cvsroot/sblim/testsuite In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12828 Modified Files: ChangeLog NEWS configure.ac Log Message: Added change control information. Index: NEWS =================================================================== RCS file: /cvsroot/sblim/testsuite/NEWS,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- NEWS 14 Apr 2005 10:38:49 -0000 1.1 +++ NEWS 31 May 2005 14:13:18 -0000 1.2 @@ -0,0 +1,5 @@ +Changes in 1.2.2 +================ + +Bugs fixed: +- 1187586 Install fails if testsuite directory exists Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/testsuite/configure.ac,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- configure.ac 14 Apr 2005 10:38:49 -0000 1.1 +++ configure.ac 31 May 2005 14:13:18 -0000 1.2 @@ -3,7 +3,7 @@ # PUT YOUR PACKAGE INFO HERE. e.g. #AC_INIT(<PACKAGE_NAME>, <PACKAGE_VERSION>, <PACKAGE_BUGREPORT>, <PACKAGE_TARBALL>) -AC_INIT(SBLIM Testsuite, 1.2.1, hei...@de..., sblim-testsuite) +AC_INIT(SBLIM Testsuite, 1.2.2, sbl...@li..., sblim-testsuite) # CHANGE THIS TO THE RELATIVE PATHNAME OF *ONE* OF THE SOURCE FILES AC_CONFIG_SRCDIR([run.sh]) Index: ChangeLog =================================================================== RCS file: /cvsroot/sblim/testsuite/ChangeLog,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ChangeLog 14 Apr 2005 10:38:49 -0000 1.1 +++ ChangeLog 31 May 2005 14:13:18 -0000 1.2 @@ -0,0 +1,5 @@ +2005-05-31 <mih...@dy...> + + * Makefile.am: + Bug 1187586: Fixed by Gareth - force symlink on installation. + |
From: Viktor M. <mih...@us...> - 2005-05-31 13:52:02
|
Update of /cvsroot/sblim/indication_helper In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3086 Modified Files: ChangeLog NEWS configure.ac Log Message: Updated ChangeLog and version in configure.ac. Index: NEWS =================================================================== RCS file: /cvsroot/sblim/indication_helper/NEWS,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- NEWS 11 May 2005 14:07:06 -0000 1.2 +++ NEWS 31 May 2005 13:51:52 -0000 1.3 @@ -1,3 +1,8 @@ +Changes in 0.4.1 +================ + +Support for CMPI Version 1.0.0. + Changes in 0.4.0 ================ Index: configure.ac =================================================================== RCS file: /cvsroot/sblim/indication_helper/configure.ac,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- configure.ac 11 May 2005 14:07:06 -0000 1.6 +++ configure.ac 31 May 2005 13:51:52 -0000 1.7 @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.53) -AC_INIT(SBLIM Indication Helper, 0.4.0, sbl...@li...,sblim-indication_helper) +AC_INIT(SBLIM Indication Helper, 0.4.1, sbl...@li...,sblim-indication_helper) AM_INIT_AUTOMAKE AC_CONFIG_SRCDIR([ind_helper.c]) AM_CONFIG_HEADER(config.h) Index: ChangeLog =================================================================== RCS file: /cvsroot/sblim/indication_helper/ChangeLog,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- ChangeLog 11 May 2005 14:07:06 -0000 1.2 +++ ChangeLog 31 May 2005 13:51:52 -0000 1.3 @@ -1,3 +1,18 @@ +2005-05-31 <mih...@dy...> + + * test/Test_addProperty.c: + * test/Test_all_functions.c: + * test/Test_genIndication.c: + * test/Test_genIndication_fail.c: + * test/Test_reg_pollfnc3_threaded.c: + * test/Test_reg_pollfnc3.c: + * test/Test_reg_pollfnc2.c: + * test/Test_reg_pollfnc.c: + * ind_helper.h: + * ind_helper.c: + In fact by Konrad: support for CMPI Version 1.00 and modified + IND_BEHAVIOUR to IND_BEHAVIOR + 2005-05-11 <mih...@dy...> * ind_helper.h: replace CMPI_VER_nn macro by CMPI_VERSION |
From: Benjamin B. <bg...@us...> - 2005-05-31 13:12:57
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/plugins/output/funcionality In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13859/Plugin/com/ibm/ecute/plugins/output/funcionality Modified Files: RSAModelCreator.java Log Message: 2.1 beta 1a fixed some CIM MOF import errors in RSA/RSM Index: RSAModelCreator.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/plugins/output/funcionality/RSAModelCreator.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- RSAModelCreator.java 10 May 2005 09:11:54 -0000 1.11 +++ RSAModelCreator.java 31 May 2005 13:12:46 -0000 1.12 @@ -595,34 +595,36 @@ // create specification constraint.createSpecification(UML2Package.eINSTANCE.getOpaqueExpression()); - String tempBody, body = ""; - // prepare constraint body content - if(value.startsWith("{")){ - int length = value.length(); - tempBody = value.substring(2, length - 2); - } else { - tempBody = value; - } - int index = tempBody.indexOf(","); - boolean multiple = false; - if (index != -1) - multiple = true; - while (index != -1){ - int length = tempBody.length(); - body = body.concat(tempBody.substring(0, index - 1)); - body = body.concat("\n"); - tempBody = tempBody.substring(index + 2); - index = tempBody.indexOf(","); - } - if (multiple){ - body = body.concat(tempBody.substring(index + 1)); - } - if (!multiple) - body = tempBody; - - //set constraint body and language - ((OpaqueExpression)constraint.getSpecification()).setBody(body); - ((OpaqueExpression)constraint.getSpecification()).setLanguage("OCL"); + // set OCL body + setOCLBody(constraint, value); +// String tempBody, body = ""; +// // prepare constraint body content +// if(value.startsWith("{")){ +// int length = value.length(); +// tempBody = value.substring(2, length - 2); +// } else { +// tempBody = value; +// } +// int index = tempBody.indexOf(","); +// boolean multiple = false; +// if (index != -1) +// multiple = true; +// while (index != -1){ +// int length = tempBody.length(); +// body = body.concat(tempBody.substring(0, index - 1)); +// body = body.concat("\n"); +// tempBody = tempBody.substring(index + 2); +// index = tempBody.indexOf(","); +// } +// if (multiple){ +// body = body.concat(tempBody.substring(index + 1)); +// } +// if (!multiple) +// body = tempBody; +// +// //set constraint body and language +// ((OpaqueExpression)constraint.getSpecification()).setBody(body); +// ((OpaqueExpression)constraint.getSpecification()).setLanguage("OCL"); // get the connection line between the constraint and the class constraint.getConstrainedElements().add(lastClass); @@ -751,8 +753,11 @@ } else if (name.equalsIgnoreCase("Key")){ if(value.equalsIgnoreCase("true")){ if(theElement instanceof Property){ - Stereotype stereo = theElement.getApplicableStereotype("CIM::Key"); - ((Property)theElement).apply(stereo); + Stereotype appliedStereo = theElement.getAppliedStereotype("CIM::Key"); + if(appliedStereo == null){ + Stereotype stereo = theElement.getApplicableStereotype("CIM::Key"); + ((Property)theElement).apply(stereo); + } } } @@ -840,6 +845,39 @@ lastQualifierType = type; } + + private void setOCLBody(Constraint constraint, String value){ + + String tempBody, body = ""; + // prepare constraint body content + if(value.startsWith("{")){ + int length = value.length(); + tempBody = value.substring(2, length - 2); + } else { + tempBody = value; + } + int index = tempBody.indexOf(","); + boolean multiple = false; + if (index != -1) + multiple = true; + while (index != -1){ + int length = tempBody.length(); + body = body.concat(tempBody.substring(0, index - 1)); + body = body.concat("\n"); + tempBody = tempBody.substring(index + 2); + index = tempBody.indexOf(","); + } + if (multiple){ + body = body.concat(tempBody.substring(index + 1)); + } + if (!multiple) + body = tempBody; + + //set constraint body and language + ((OpaqueExpression)constraint.getSpecification()).setBody(body); + ((OpaqueExpression)constraint.getSpecification()).setLanguage("OCL"); + + } /*************************************************************************** * Private Methods |
From: Benjamin B. <bg...@us...> - 2005-05-31 13:12:57
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/UMLBuffer In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13859/Plugin/com/ibm/ecute/UMLBuffer Modified Files: UMLBuffer.java Log Message: 2.1 beta 1a fixed some CIM MOF import errors in RSA/RSM Index: UMLBuffer.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/UMLBuffer/UMLBuffer.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- UMLBuffer.java 8 Apr 2005 09:11:16 -0000 1.7 +++ UMLBuffer.java 31 May 2005 13:12:47 -0000 1.8 @@ -568,36 +568,43 @@ int result = -1; // RSA if (UMLProgram instanceof RSAModelCreator){ - // System.out.println("UMLProgram is an instance of RSAModelCreator"); + + boolean aggregate = false; // get the first qualifier of each association role to find out // in which role the aggregate is defined ArrayList qualifiers1 = role1.getQualifiers(true); - UMLQualifier role1Qualifier = (UMLQualifier) qualifiers1.get(0); - ArrayList qualifiers2 = role2.getQualifiers(true); - UMLQualifier role2Qualifier = (UMLQualifier) qualifiers2.get(0); - - // if aggregate is defined in role 1 (MOF file) then AddAssociation is - // called with role 2 first to get the diamond on the correct end of the - // association (the diamond is in RSA on the side of the second role - // which is passed to AddAssociation) - if (role1Qualifier.name.equalsIgnoreCase("Aggregate")){ - System.out.println("Role 1 is AGGREGATE"); - aggregateRole1 = true; - result = UMLProgram.AddAssociation(role2.endPointName, - role2.name, role1.endPointName, role1.name, RclassDiagram); + if(qualifiers1.size() > 0){ + UMLQualifier role1Qualifier = (UMLQualifier) qualifiers1.get(0); + //if aggregate is defined in role 1 (MOF file) then AddAssociation is + // called with role 2 first to get the diamond on the correct end of the + // association (the diamond is in RSA on the side of the second role + // which is passed to AddAssociation) + if (role1Qualifier.name.equalsIgnoreCase("Aggregate")){ + //System.out.println("Role 1 is AGGREGATE"); + aggregate = true; + aggregateRole1 = true; + result = UMLProgram.AddAssociation(role2.endPointName, + role2.name, role1.endPointName, role1.name, RclassDiagram); + } } - // if aggregate is defined in role 2 (MOF file) - // aggregateRole1 is set to false to get the qualifiers (with SetQualifiers) - // to the correct end of the aggregation/composition - else if (role2Qualifier.name.equalsIgnoreCase("Aggregate")){ - System.out.println("Role 2 is AGGREGATE"); - aggregateRole1 = false; - result = UMLProgram.AddAssociation(role1.endPointName, - role1.name, role2.endPointName, role2.name, RclassDiagram); + ArrayList qualifiers2 = role2.getQualifiers(true); + if(qualifiers2.size() > 0){ + UMLQualifier role2Qualifier = (UMLQualifier) qualifiers2.get(0); + // if aggregate is defined in role 2 (MOF file) + // aggregateRole1 is set to false to get the qualifiers (with SetQualifiers) + // to the correct end of the aggregation/composition + if (role2Qualifier.name.equalsIgnoreCase("Aggregate")){ + //System.out.println("Role 2 is AGGREGATE"); + aggregate = true; + aggregateRole1 = false; + result = UMLProgram.AddAssociation(role1.endPointName, + role1.name, role2.endPointName, role2.name, RclassDiagram); + } + } // if the association is no aggregation or composition - } else { + if(!aggregate) { //System.out.println("Normal association"); //System.out.println("Role 1 end point = " + role1.endPointName + " Role 1 name = " + role1.name); //System.out.println("Role 2 end point = " + role2.endPointName + " Role 2 name = " + role2.name); |
From: Benjamin B. <bg...@us...> - 2005-05-31 13:12:57
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/dialogs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13859/Plugin/com/ibm/ecute/rsa/core/internal/dialogs Modified Files: EditQualifiersDialog.java Log Message: 2.1 beta 1a fixed some CIM MOF import errors in RSA/RSM Index: EditQualifiersDialog.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/dialogs/EditQualifiersDialog.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- EditQualifiersDialog.java 25 May 2005 15:45:48 -0000 1.4 +++ EditQualifiersDialog.java 31 May 2005 13:12:47 -0000 1.5 @@ -50,10 +50,12 @@ import org.eclipse.uml2.AssociationClass; import org.eclipse.uml2.Class; import org.eclipse.uml2.Comment; +import org.eclipse.uml2.Constraint; import org.eclipse.uml2.Element; import org.eclipse.uml2.Model; import org.eclipse.uml2.MultiplicityElement; import org.eclipse.uml2.NamedElement; +import org.eclipse.uml2.OpaqueExpression; import org.eclipse.uml2.Operation; import org.eclipse.uml2.Package; import org.eclipse.uml2.PackageableElement; @@ -74,7 +76,10 @@ import com.ibm.xtools.emf.msl.EditingDomain; import com.ibm.xtools.emf.msl.ResourceSetModifyOperation; import com.ibm.xtools.modeler.UMLModeler; +import com.ibm.xtools.notation.Diagram; import com.ibm.xtools.uml.core.IUMLHelper; +import com.ibm.xtools.uml.diagram.IUMLDiagramHelper; +import com.ibm.xtools.umlnotation.UMLDiagramKind; /** * Copyright (c) 2003, International Business Machines @@ -107,6 +112,7 @@ private Color WHITE = null; Model uml2Model; + IUMLDiagramHelper diagramHelper = UMLModeler.getUMLDiagramHelper(); // value tab Composite valComposite; @@ -2536,6 +2542,33 @@ return false; } } + + public boolean isDirectMapped(){ + + if( this.name.equalsIgnoreCase("Association")|| + this.name.equalsIgnoreCase("Aggregation")|| + this.name.equalsIgnoreCase("Composition")|| + this.name.equalsIgnoreCase("Aggregate")|| + this.name.equalsIgnoreCase("In")|| + this.name.equalsIgnoreCase("Out")|| + this.name.equalsIgnoreCase("Inout")|| + this.name.equalsIgnoreCase("Min")|| + this.name.equalsIgnoreCase("Max")|| + this.name.equalsIgnoreCase("Octectstring")|| + this.name.equalsIgnoreCase("Static")|| + this.name.equalsIgnoreCase("Write")|| + this.name.equalsIgnoreCase("Description")|| + this.name.equalsIgnoreCase("Abstract")|| + this.name.equalsIgnoreCase("Deprecated")|| + this.name.equalsIgnoreCase("Key")|| + this.name.equalsIgnoreCase("ArrayType")|| + this.name.equalsIgnoreCase("OCL") + ){ + return true; + } else { + return false; + } + } } private void setElementLabel(){ @@ -2690,6 +2723,7 @@ if(!setDefaultValue){ EditingDomain editingDomain = UMLModeler.getEditingDomain(); +// if(valueObject.name.equalsIgnoreCase("OCL")) valueObject.index = -1; try { if (valueObject.index == -1) { @@ -2699,16 +2733,8 @@ protected void execute(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { - if(valueObject.name == "Description"){ - EList list = element.getOwnedComments(); - Iterator it = list.iterator(); - while (it.hasNext()){ - Comment comment = (Comment)it.next(); - Stereotype stereo = comment.getApplicableStereotype("Default::Documentation"); - if(stereo != null){ - comment.setBody(valueObject.value); - } - } + if(valueObject.isDirectMapped()){ + mapQualifierToModel(element, valueObject.name, valueObject.value); } else { Stereotype cimStereotype = element.getAppliedStereotype("CIM::Qualifiers"); int stereotypePropertyIndex = ((List) element.getValue(cimStereotype, "QualifierName")) @@ -2798,6 +2824,113 @@ } } + + public void mapQualifierToModel(Element element, String qualifierName, String newValue){ + + // DESCRIPTION + if(qualifierName.equalsIgnoreCase("Description")){ + EList list = element.getOwnedComments(); + Iterator it = list.iterator(); + if(it.hasNext()){ + while (it.hasNext()){ + Comment comment = (Comment)it.next(); + Stereotype stereo = comment.getApplicableStereotype("Default::Documentation"); + if(stereo != null){ + comment.setBody(newValue); + } + } + } else { + Comment descr = element.createOwnedComment(UML2Package.eINSTANCE.getComment()); + descr.setBody(newValue); + Stereotype stereo = descr.getApplicableStereotype("Default::Documentation"); + descr.apply(stereo); + } + } + + // DEPRECATED + if(qualifierName.equalsIgnoreCase("Deprecated")){ + Stereotype appliedStereo = element.getAppliedStereotype("CIM::Deprecated"); + if(appliedStereo == null){ + Stereotype stereo = element.getApplicableStereotype("CIM::Deprecated"); + element.apply(stereo); + element.setValue(stereo, "Value", newValue); + } else { + if(newValue.equalsIgnoreCase("null")){ + element.unapply(appliedStereo); + } else { + element.setValue(appliedStereo, "Value", newValue); + } + } + } +/* + // OCL + if(qualifierName.equalsIgnoreCase("OCL")){ + if (element instanceof Class){ + List elementList = ((Class)element).getPackage().getOwnedElements(); + ArrayList constraintList = new ArrayList(); + for (int i = 0; i < elementList.size(); i++){ + if (elementList.get(i) instanceof Constraint) + constraintList.add(elementList.get(i)); + } + boolean foundConstraint = false; + if (constraintList != null){ + for(int j = 0; j < constraintList.size(); j++){ + Constraint constraint = (Constraint)constraintList.get(j); + List constrainedElements = constraint.getConstrainedElements(); + for(int k = 0; k < constrainedElements.size(); k++){ + if(constrainedElements.get(k) instanceof Class){ + if(((Class)constrainedElements.get(k)).getName().equalsIgnoreCase(((Class)element).getName())){ + + foundConstraint = true; + + if(newValue.equalsIgnoreCase("null")){ + elementList.remove(constraint); + //constraint.destroy(); + //diagramHelper.destroyView((View)constraint); + } + + String tempBody, body = ""; + // prepare constraint body content + if(newValue.startsWith("{")){ + int length = newValue.length(); + tempBody = newValue.substring(2, length - 2); + } else { + tempBody = newValue; + } + int index = tempBody.indexOf(","); + boolean multiple = false; + if (index != -1) + multiple = true; + while (index != -1){ + int length = tempBody.length(); + body = body.concat(tempBody.substring(0, index - 1)); + body = body.concat("\n"); + tempBody = tempBody.substring(index + 2); + index = tempBody.indexOf(","); + } + if (multiple){ + body = body.concat(tempBody.substring(index + 1)); + } + if (!multiple) + body = tempBody; + + //set constraint body and language + ((OpaqueExpression)constraint.getSpecification()).setBody(body); + + + } + } + } + } + } + + if(!foundConstraint){ + createClassOCL((Class)element, newValue); + } + } + }*/ + } + private Class getSelectedClass(String name, Package package_, boolean otherPackages) { Class theClass = null; @@ -3189,6 +3322,95 @@ resetRemovedValues(); } + + private void createClassOCL(Class lastClass, String value){ + Package package_ = lastClass.getNearestPackage(); + Constraint constraint = (Constraint)package_.createOwnedMember(UML2Package.eINSTANCE.getConstraint()); + constraint.setName("OCL " + lastClass.getName()); + + // create specification + constraint.createSpecification(UML2Package.eINSTANCE.getOpaqueExpression()); + setOCLBody(constraint, value); +// String tempBody, body = ""; +// // prepare constraint body content +// if(value.startsWith("{")){ +// int length = value.length(); +// tempBody = value.substring(2, length - 2); +// } else { +// tempBody = value; +// } +// int index = tempBody.indexOf(","); +// boolean multiple = false; +// if (index != -1) +// multiple = true; +// while (index != -1){ +// int length = tempBody.length(); +// body = body.concat(tempBody.substring(0, index - 1)); +// body = body.concat("\n"); +// tempBody = tempBody.substring(index + 2); +// index = tempBody.indexOf(","); +// } +// if (multiple){ +// body = body.concat(tempBody.substring(index + 1)); +// } +// if (!multiple) +// body = tempBody; +// +// //set constraint body and language +// ((OpaqueExpression)constraint.getSpecification()).setBody(body); +// ((OpaqueExpression)constraint.getSpecification()).setLanguage("OCL"); + + // get the connection line between the constraint and the class + constraint.getConstrainedElements().add(lastClass); + + // add constraint to diagram + ArrayList list = new ArrayList(); + list.add(constraint); + List diagrams = diagramHelper.getDiagrams(package_, UMLDiagramKind.CLASS_LITERAL); + Iterator it = diagrams.iterator(); + Diagram thisDiagram = null; + while(it.hasNext()){ + Diagram diagram = (Diagram)it.next(); + if(diagram.getName().equalsIgnoreCase("Main")) + thisDiagram = diagram; + } + if (thisDiagram != null){ + diagramHelper.createViews(thisDiagram, list); + } + } + + private void setOCLBody(Constraint constraint, String value){ + + String tempBody, body = ""; + // prepare constraint body content + if(value.startsWith("{")){ + int length = value.length(); + tempBody = value.substring(2, length - 2); + } else { + tempBody = value; + } + int index = tempBody.indexOf(","); + boolean multiple = false; + if (index != -1) + multiple = true; + while (index != -1){ + int length = tempBody.length(); + body = body.concat(tempBody.substring(0, index - 1)); + body = body.concat("\n"); + tempBody = tempBody.substring(index + 2); + index = tempBody.indexOf(","); + } + if (multiple){ + body = body.concat(tempBody.substring(index + 1)); + } + if (!multiple) + body = tempBody; + + //set constraint body and language + ((OpaqueExpression)constraint.getSpecification()).setBody(body); + ((OpaqueExpression)constraint.getSpecification()).setLanguage("OCL"); + + } private class EditValueDialog extends Dialog{ |
From: Benjamin B. <bg...@us...> - 2005-05-31 13:12:57
|
Update of /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/properties In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13859/Plugin/com/ibm/ecute/rsa/core/internal/properties Modified Files: QualifiersPropertySection.java Log Message: 2.1 beta 1a fixed some CIM MOF import errors in RSA/RSM Index: QualifiersPropertySection.java =================================================================== RCS file: /cvsroot/sblim/ecute/Plugin/com/ibm/ecute/rsa/core/internal/properties/QualifiersPropertySection.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- QualifiersPropertySection.java 25 May 2005 15:45:48 -0000 1.15 +++ QualifiersPropertySection.java 31 May 2005 13:12:47 -0000 1.16 @@ -842,65 +842,65 @@ update(notification, eobject); } - public void mapQualifierToModel(Element element, String qualifierName, String newValue){ - if (element instanceof Class){ - if(qualifierName.equalsIgnoreCase("Description")){ - Comment descr = element.createOwnedComment(UML2Package.eINSTANCE.getComment()); - descr.setBody(newValue); - Stereotype stereo = descr.getApplicableStereotype("Default::Documentation"); - descr.apply(stereo); - } - if(qualifierName.equalsIgnoreCase("OCL")){ - List elementList = ((Class)element).getPackage().getOwnedElements(); - ArrayList constraintList = new ArrayList(); - for (int i = 0; i < elementList.size(); i++){ - if (elementList.get(i) instanceof Constraint) - constraintList.add(elementList.get(i)); - } - if (constraintList != null){ - for(int j = 0; j < constraintList.size(); j++){ - Constraint constraint = (Constraint)constraintList.get(j); - List constrainedElements = constraint.getConstrainedElements(); - for(int k = 0; k < constrainedElements.size(); k++){ - if(constrainedElements.get(k) instanceof Class){ - if(((Class)constrainedElements.get(k)).getName().equalsIgnoreCase(((Class)element).getName())){ - String tempBody, body = ""; - // prepare constraint body content - if(newValue.startsWith("{")){ - int length = newValue.length(); - tempBody = newValue.substring(2, length - 2); - } else { - tempBody = newValue; - } - int index = tempBody.indexOf(","); - boolean multiple = false; - if (index != -1) - multiple = true; - while (index != -1){ - int length = tempBody.length(); - body = body.concat(tempBody.substring(0, index - 1)); - body = body.concat("\n"); - tempBody = tempBody.substring(index + 2); - index = tempBody.indexOf(","); - } - if (multiple){ - body = body.concat(tempBody.substring(index + 1)); - } - if (!multiple) - body = tempBody; - - //set constraint body and language - ((OpaqueExpression)constraint.getSpecification()).setBody(body); - - - } - } - } - } - } - } - } - } +// public void mapQualifierToModel(Element element, String qualifierName, String newValue){ +// if (element instanceof Class){ +// if(qualifierName.equalsIgnoreCase("Description")){ +// Comment descr = element.createOwnedComment(UML2Package.eINSTANCE.getComment()); +// descr.setBody(newValue); +// Stereotype stereo = descr.getApplicableStereotype("Default::Documentation"); +// descr.apply(stereo); +// } +// if(qualifierName.equalsIgnoreCase("OCL")){ +// List elementList = ((Class)element).getPackage().getOwnedElements(); +// ArrayList constraintList = new ArrayList(); +// for (int i = 0; i < elementList.size(); i++){ +// if (elementList.get(i) instanceof Constraint) +// constraintList.add(elementList.get(i)); +// } +// if (constraintList != null){ +// for(int j = 0; j < constraintList.size(); j++){ +// Constraint constraint = (Constraint)constraintList.get(j); +// List constrainedElements = constraint.getConstrainedElements(); +// for(int k = 0; k < constrainedElements.size(); k++){ +// if(constrainedElements.get(k) instanceof Class){ +// if(((Class)constrainedElements.get(k)).getName().equalsIgnoreCase(((Class)element).getName())){ +// String tempBody, body = ""; +// // prepare constraint body content +// if(newValue.startsWith("{")){ +// int length = newValue.length(); +// tempBody = newValue.substring(2, length - 2); +// } else { +// tempBody = newValue; +// } +// int index = tempBody.indexOf(","); +// boolean multiple = false; +// if (index != -1) +// multiple = true; +// while (index != -1){ +// int length = tempBody.length(); +// body = body.concat(tempBody.substring(0, index - 1)); +// body = body.concat("\n"); +// tempBody = tempBody.substring(index + 2); +// index = tempBody.indexOf(","); +// } +// if (multiple){ +// body = body.concat(tempBody.substring(index + 1)); +// } +// if (!multiple) +// body = tempBody; +// +// //set constraint body and language +// ((OpaqueExpression)constraint.getSpecification()).setBody(body); +// +// +// } +// } +// } +// } +// } +// } +// } +// } public boolean getShowAll(){ return showAllButton.getSelection(); |
From: Adrian S. <a3s...@us...> - 2005-05-31 09:23:59
|
Update of /cvsroot/sblim/sfcb In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18971 Modified Files: brokerUpc.c Log Message: Fixed [ 1206682 ] change error when delete indication handler in use Index: brokerUpc.c =================================================================== RCS file: /cvsroot/sblim/sfcb/brokerUpc.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- brokerUpc.c 9 Mar 2005 12:25:09 -0000 1.1.1.1 +++ brokerUpc.c 31 May 2005 09:23:50 -0000 1.2 @@ -143,6 +143,16 @@ #endif } +void buildStatus(BinResponseHdr *resp, CMPIStatus *st) +{ + if (st==NULL) return; + st->rc=resp->rc; + if (resp->rc && resp->count==1 && resp->object[0].type==MSG_SEG_CHARS && resp->object[0].length) { + st->msg=native_new_CMPIString((char*)resp->object[0].data,NULL); + } + else st->msg=NULL; +} + //--------------------------------------------------- //--- //- Instance support @@ -292,7 +302,7 @@ resp = invokeProvider(&binCtx); closeProviderContext(&binCtx); resp->rc--; - st.rc = resp->rc; + buildStatus(resp,&st); if (resp->rc == CMPI_RC_OK) { inst = relocateSerializedInstance(resp->object[0].data); tInst=inst->ft->clone(inst,NULL); @@ -358,7 +368,7 @@ resp = invokeProvider(&binCtx); closeProviderContext(&binCtx); resp->rc--; - st.rc = resp->rc; + buildStatus(resp,&st); if (resp->rc == CMPI_RC_OK) { op = relocateSerializedObjectPath(resp->object[0].data); tOp=op->ft->clone(op,NULL); @@ -428,7 +438,7 @@ resp = invokeProvider(&binCtx); closeProviderContext(&binCtx); resp->rc--; - st.rc = resp->rc; + buildStatus(resp,&st); if (resp->rc == CMPI_RC_OK) { free(resp); } @@ -479,7 +489,7 @@ resp = invokeProvider(&binCtx); closeProviderContext(&binCtx); resp->rc--; - st.rc = resp->rc; + buildStatus(resp,&st); if (resp->rc == CMPI_RC_OK) { free(resp); } @@ -830,7 +840,7 @@ closeProviderContext(&binCtx); resp->rc--; - if (rc) st.rc = resp->rc; + buildStatus(resp,&st); if (resp->rc == CMPI_RC_OK) { if (out) { tOut = relocateSerializedArgs(resp->object[0].data); |
From: Adrian S. <a3s...@us...> - 2005-05-31 07:19:03
|
Update of /cvsroot/sblim/cmpi-tests/cmpi-instancetest/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18507/src Modified Files: TST_InstanceTest.c Log Message: Fixed [ 1211392 ] cmpi-instancetest ein reports free() invalid pointer Index: TST_InstanceTest.c =================================================================== RCS file: /cvsroot/sblim/cmpi-tests/cmpi-instancetest/src/TST_InstanceTest.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- TST_InstanceTest.c 24 May 2005 23:00:23 -0000 1.6 +++ TST_InstanceTest.c 31 May 2005 07:18:51 -0000 1.7 @@ -954,7 +954,7 @@ } /* Add a new empty entry to the instances list */ - newinstances = (CMPIInstance **)realloc(instances, (sizeinstances+1)*sizeof(CMPIInstance *)); + newinstances = (CMPIInstance **)realloc(instances, (sizeinstances+2)*sizeof(CMPIInstance *)); if (newinstances == NULL) { _OSBASE_TRACE(1,("%s:_addinstance() realloc() failed", _PROVIDERNAME)); CMSetStatusWithChars(_BROKER, &status, CMPI_RC_ERROR_SYSTEM, "realloc() failed"); @@ -1505,6 +1505,7 @@ /* Initialize an empty NULL terminated instances list */ instances = (CMPIInstance **)malloc(sizeof(CMPIInstance *)); + printf("Initialize(): instances: %p\n",instances); instances[0] = NULL; sizeinstances = 1; |
From: Adrian S. <a3s...@us...> - 2005-05-30 01:32:33
|
Update of /cvsroot/sblim/sfcb In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19167 Modified Files: cimXmlGen.c objectImpl.c providerDrv.c providerMgr.c Log Message: Fixed [ 1201073 ] Method_boolean_in.001.xml returns false and [ 1201084 ] Method_char16_in.001.xml causes sfcb xml parser error Also fixed unreported CMPIDateTime error when datetime value returned by invokeMethod Index: cimXmlGen.c =================================================================== RCS file: /cvsroot/sblim/sfcb/cimXmlGen.c,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- cimXmlGen.c 26 Apr 2005 21:58:46 -0000 1.7 +++ cimXmlGen.c 30 May 2005 01:32:24 -0000 1.8 @@ -255,7 +255,7 @@ } switch (type) { - case CMPI_chars: + case CMPI_char16: value.char16 = *val; break; case CMPI_string: @@ -289,6 +289,7 @@ break; case CMPI_boolean: value.boolean = strcasecmp(val, "false"); + if (value.boolean) value.boolean = 1; break; case CMPI_real32: sscanf(val, "%f", &value.real32); Index: objectImpl.c =================================================================== RCS file: /cvsroot/sblim/sfcb/objectImpl.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- objectImpl.c 27 May 2005 15:09:13 -0000 1.6 +++ objectImpl.c 30 May 2005 01:32:24 -0000 1.7 @@ -2166,6 +2166,11 @@ data->value.string = native_new_CMPIString(str, NULL); data->type = CMPI_string; } + if (data->type == CMPI_dateTime) { + const char *str = + ClObjectGetClString(&arg->hdr, (ClString *) & data->value.chars); + data->value.dateTime = native_new_CMPIDateTime_fromChars(str, NULL); + } if (data->type & CMPI_ARRAY) { data->value.dataPtr.ptr = (void *) ClObjectGetClArray(&arg->hdr, (ClArray *) & data->value.array); Index: providerDrv.c =================================================================== RCS file: /cvsroot/sblim/sfcb/providerDrv.c,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- providerDrv.c 29 Apr 2005 12:48:30 -0000 1.13 +++ providerDrv.c 30 May 2005 01:32:24 -0000 1.14 @@ -538,6 +538,7 @@ { _SFCB_ENTER(TRACE_PROVIDERDRV, "sendResponse"); int i, l, rvl=0, ol, size, dmy; + char str_time[26]; BinResponseHdr *buf; size = sizeof(BinResponseHdr) + ((hdr->count - 1) * sizeof(MsgSegment)); @@ -556,6 +557,12 @@ hdr->rvEnc=setCharsMsgSegment((char*)hdr->rv.value.string); rvl=hdr->rvEnc.length; break; + case CMPI_dateTime: + dateTime2chars(hdr->rv.value.dateTime, NULL, str_time); + hdr->rvEnc.type=MSG_SEG_CHARS; + hdr->rvEnc.length=rvl=26; + hdr->rvEnc.data=&str_time; + break; case CMPI_ref: mlogf(M_ERROR,M_SHOW,"-#- not supporting refs\n"); abort(); @@ -578,7 +585,7 @@ buf->rvEnc.data = (void *) l; l += ol; break; - } + } size=l; } Index: providerMgr.c =================================================================== RCS file: /cvsroot/sblim/sfcb/providerMgr.c,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- providerMgr.c 22 May 2005 18:45:03 -0000 1.9 +++ providerMgr.c 30 May 2005 01:32:24 -0000 1.10 @@ -947,6 +947,9 @@ if (resp->rvValue) { if (resp->rv.type==CMPI_chars) resp->rv.value.chars=(int)resp->rvEnc.data+(char*)resp; + else if (resp->rv.type==CMPI_dateTime) + resp->rv.value.dateTime= + native_new_CMPIDateTime_fromChars((int)resp->rvEnc.data+(char*)resp,NULL); } for (i = 0; i < resp->count; i++) { resp->object[i].data=(void*)((int)resp->object[i].data+(char*)resp); |