A list for the developers of CellML tools

Text archives Help


[cellml-dev] CellML wchar sizes


Chronological Thread 
  • From: lpsmith at spod-central.org (Lucian Smith)
  • Subject: [cellml-dev] CellML wchar sizes
  • Date: Thu, 3 Dec 2009 23:34:21 +0000

Ok, I appear to be taking things in tiny tiny baby steps, but I keep
thinking that if only I understood the next bit, I'd get it. If we take a
slightly-modified version of your code:

nsresult rv;
nsCOMPtr<cellml_apiICellMLBootstrap>
boot(do_GetService(CELLML_BOOTSTRAP_CONTRACTID, &rv));
NS_ENSURE_SUCCESS(rv, );
nsCOMPtr<cellml_apiIModel> mod;
rv = boot->CreateModel(NS_LITERAL_STRING("1.1"), getter_AddRefs(mod));
NS_ENSURE_SUCCESS(rv, );

(NS_ENSURE_SUCCESS(rv, rv) didn't compile for some reason; I saw the above
version in DataCollector.cpp so I went with that and it compiled. I don't
know why, but I'm not complaining...)

To me, it seemed like since you created 'boot' using those methods, and
then called a function that was originally defined for the CellML
Bootstrap interface thingy, I could then do the following:

nsCOMPtr<cellml_apiICellMLComponentSet> components = mod->localComponents();

But... no such luck:

error: 'class cellml_apiIModel' has no member named 'localComponents'

So how do I get at those functions like 'localComponents' that I used to
be able to call when 'mod' was a cellml_api::Model* ?

-Lucian




Archive powered by MHonArc 2.6.18.

Top of page