PG

The Model.setTemporaryUserInfo ( Occ ObjOrCxnOcc, int nType, String sText ) method is a neat way of indicating semantic problems with models from ordinary reports (not just semantic checks) that depend on specific conventions: you get a highlight and a text on each connection or object that you want to indicate a warning for, transiently.

However, it seems to work only in the Designer/Architect client: I have not managed to get any indication or problems when running it in Connect or Connect Designer. (Portal version: 10.0.17.4.1609029; ARIS version:  10.0.17.4.1609029). Am I missing something?

Is there an overview of what report methods and functionality (like Fragments, or Architect method & filter management) differ between the Java Designer client and the Connect Designer?

by Martin Schröder
Badge for 'Contributor' achievement
Posted on Tue, 08/23/2022 - 16:47

Hello Pontus,

on https://documentation.softwareag.com/aris/Architect/10-0sr18/yaa10-0sr18e/index.htm
> Additional documentation
you can find references for the differences with regard to client/license types

    Functional Product Matrix
     Method Matrix
     Report Matrix
     Technical Product Matrix

and changes between Aris releases: Report Script Changes

re: setTemporaryUserInfo

I did not try this one, but in general it is a pity that differences between the client types are not marked in the script help. The only hint on methods available in the thin client is the historic formula "This method is also available in ARIS Publisher report." And it happens to be the case for

Report class Context - Method addActionResult

Context.addActionResult(Constants.ACTION_INFO, "temporary information", currentObjOcc) //displays a temporary info text next to an object in a model 

Maybe it is an alternative for your purpose.

Regards, Martin

0
by Michel Bénard
Posted on Fri, 08/26/2022 - 15:05

Hi Pontus

Please find below a report code snippet which run from Aris Connect on models, display temporary decorations around multiple occurrences of the same definition object . Works fine on Aris Connect Enterprise 10.0.13

 

var g_nLoc = Context.getSelectedLanguage();


function main()
{

    var models = ArisData.getSelectedModels();
    for( var m in models)
    {
        try
        {
            var model=models[m]  ;
            model.openModel()  ;
            var objDefsMap = getOccListWithCount(model)  ;
            decorateModel(model,objDefsMap)  ;
        }
        catch(ex)
        {
            var line = ex.lineNumber;
            var message = ex.message;
            var filename = ex.fileName;
            Dialogs.MsgBox("Exception in file "+filename+", line "+line+":\n"+message) ;
        }
    }
}
main();

/**
* Return an associative array
* Key is Guid of the object definition GUID
* Value is an array :
*  - first element is the number of occurrences in the model
* - second element is the object name
* - third element is the list of ccurrences in the model
*/
function getOccListWithCount(model)
{
    var ojbOccs = model.ObjOccList();
    var objDefsMap = {};
    for( var o in ojbOccs)
    {
        var objDef = ojbOccs[o].ObjDef();
        var guid = objDef.GUID();
        if (guid in objDefsMap)
        {
            objDefsMap[guid][0]++;
            objDefsMap[guid][2].push(ojbOccs[o]);
        }
        else
            objDefsMap[guid]=[1,objDef.Name(g_nLoc),[ojbOccs[o]]];
    }
    return objDefsMap;
}
/**
* add temporary user info to each duplicate occurrence in the model
*/
function decorateModel(model,objDefsMap)
{
    for (var g in objDefsMap)
    {
        if (objDefsMap[g][0]>1)
        {
            for(var occ in objDefsMap[g][2])
                model.setTemporaryUserInfo(objDefsMap[g][2][occ],Constants.MODEL_INFO_WARNING,getString("DUPLICATE"))   ;
        }
    }
}

0

Featured achievement

Question Solver
Share your expertise and have your answer accepted as best reply.
Recent Unlocks
  • CR
  • BH
  • Profile picture for user Ivan.Ivanov.softwareag.com
  • Profile picture for user mscheid
  • MS
  • PacMan

Leaderboard

|
icon-arrow-down icon-arrow-cerulean-left icon-arrow-cerulean-right icon-arrow-down icon-arrow-left icon-arrow-right icon-arrow icon-back icon-close icon-comments icon-correct-answer icon-tick icon-download icon-facebook icon-flag icon-google-plus icon-hamburger icon-in icon-info icon-instagram icon-login-true icon-login icon-mail-notification icon-mail icon-mortarboard icon-newsletter icon-notification icon-pinterest icon-plus icon-rss icon-search icon-share icon-shield icon-snapchat icon-star icon-tutorials icon-twitter icon-universities icon-videos icon-views icon-whatsapp icon-xing icon-youtube icon-jobs icon-heart icon-heart2 aris-express bpm-glossary help-intro help-design Process_Mining_Icon help-publishing help-administration help-dashboarding help-archive help-risk icon-knowledge icon-question icon-events icon-message icon-more icon-pencil forum-icon icon-lock