Skip to content

Commit

Permalink
chore: doxy formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
allanbowe committed Nov 29, 2020
1 parent def0cc8 commit 6f86ed6
Show file tree
Hide file tree
Showing 20 changed files with 152 additions and 184 deletions.
168 changes: 76 additions & 92 deletions all.sas

Large diffs are not rendered by default.

7 changes: 3 additions & 4 deletions viya/mv_createfolder.sas
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -42,7 +41,7 @@
%end;

%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand Down Expand Up @@ -121,7 +120,7 @@ options noquotelenmax;
out=&fname2
&oauth_bearer
url=%unquote(%superq(href));
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
Expand Down
42 changes: 21 additions & 21 deletions viya/mv_createwebservice.sas
Original file line number Diff line number Diff line change
@@ -1,27 +1,28 @@
/**
@file mv_createwebservice.sas
@brief Creates a JobExecution web service if it doesn't already exist
@details Code is passed in as one or more filerefs.
@details
Code is passed in as one or more filerefs.
%* Step 1 - compile macros ;
filename mc url "https://raw.githubusercontent.com/sasjs/core/main/all.sas";
%inc mc;
%* Step 1 - compile macros ;
filename mc url "https://raw.githubusercontent.com/sasjs/core/main/all.sas";
%inc mc;
%* Step 2 - Create some code and add it to a web service;
filename ft15f001 temp;
parmcards4;
%webout(FETCH) %* fetch any tables sent from frontend;
%* do some sas, any inputs are now already WORK tables;
data example1 example2;
set sashelp.class;
run;
%* send data back;
%webout(OPEN)
%webout(ARR,example1) * Array format, fast, suitable for large tables ;
%webout(OBJ,example2) * Object format, easier to work with ;
%webout(CLOSE)
;;;;
%mv_createwebservice(path=/Public/app/common,name=appinit)
%* Step 2 - Create some code and add it to a web service;
filename ft15f001 temp;
parmcards4;
%webout(FETCH) %* fetch any tables sent from frontend;
%* do some sas, any inputs are now already WORK tables;
data example1 example2;
set sashelp.class;
run;
%* send data back;
%webout(OPEN)
%webout(ARR,example1) * Array format, fast, suitable for large tables ;
%webout(OBJ,example2) * Object format, easier to work with ;
%webout(CLOSE)
;;;;
%mv_createwebservice(path=/Public/app/common,name=appinit)
Notes:
Expand Down Expand Up @@ -54,8 +55,7 @@
a shared context - see https://go.documentation.sas.com/?docsetId=calcontexts&docsetTarget=n1hjn8eobk5pyhn1wg3ja0drdl6h.htm&docsetVersion=3.5&locale=en
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
**/

Expand Down
9 changes: 4 additions & 5 deletions viya/mv_deletefoldermember.sas
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
@file mv_deletefoldermember.sas
@brief Deletes an item in a Viya folder
@details If not executed in Studio 5+ will expect oauth token in a global
@details If not executed in Studio 5+ will expect oauth token in a global
macro variable (default ACCESS_TOKEN).
filename mc url "https://raw.githubusercontent.com/sasjs/core/main/all.sas";
Expand All @@ -20,8 +20,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -48,7 +47,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand Down Expand Up @@ -129,7 +128,7 @@ run;
%return;
%end;
proc http method="DELETE" url="&base_uri&uri" &oauth_bearer;
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
Expand Down
9 changes: 4 additions & 5 deletions viya/mv_deletejes.sas
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
@file mv_deletejes.sas
@brief Creates a job execution service if it does not already exist
@details If not executed in Studio 5+ will expect oauth token in a global
@details If not executed in Studio 5+ will expect oauth token in a global
macro variable (default ACCESS_TOKEN).
filename mc url "https://raw.githubusercontent.com/sasjs/core/main/all.sas";
Expand All @@ -19,8 +19,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -46,7 +45,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand Down Expand Up @@ -126,7 +125,7 @@ run;
%return;
%end;
proc http method="DELETE" url="&uri" &oauth_bearer;
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
Expand Down
11 changes: 5 additions & 6 deletions viya/mv_deleteviyafolder.sas
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/**
@file mv_deleteviyafolder.sas
@brief Creates a viya folder if that folder does not already exist
@details If not running in Studo 5 +, will expect an oauth token in a global
@details If not running in Studo 5 +, will expect an oauth token in a global
macro variable (default ACCESS_TOKEN).
options mprint;
Expand All @@ -16,8 +16,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -42,7 +41,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand Down Expand Up @@ -121,10 +120,10 @@ run;
%let fname2=%mf_getuniquefileref();
proc http method='DELETE' out=&fname2 &oauth_bearer
url=%unquote(%superq(href));
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
%end;
'Accept'='*/*'; /**/
run;
%if &SYS_PROCHTTP_STATUS_CODE ne 204 %then %do;
Expand Down
7 changes: 3 additions & 4 deletions viya/mv_getaccesstoken.sas
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@
@brief deprecated - replaced by mv_tokenrefresh.sas
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mv_tokenrefresh.sas
**/

%macro mv_getaccesstoken(client_id=someclient
,client_secret=somesecret
,grant_type=authorization_code
Expand Down
7 changes: 3 additions & 4 deletions viya/mv_getapptoken.sas
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@
@brief deprecated - replaced by mv_registerclient.sas
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mv_registerclient.sas
**/

%macro mv_getapptoken(client_id=someclient
,client_secret=somesecret
,grant_type=authorization_code
Expand Down
5 changes: 2 additions & 3 deletions viya/mv_getclients.sas
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand Down Expand Up @@ -95,7 +94,7 @@ run;



/* clear refs
/* clear refs
filename &fname1 clear;
libname &libref1 clear;
*/
Expand Down
3 changes: 1 addition & 2 deletions viya/mv_getfoldermembers.sas
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand Down
7 changes: 3 additions & 4 deletions viya/mv_getgroupmembers.sas
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -56,7 +55,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand All @@ -73,7 +72,7 @@ options noquotelenmax;
%let fname1=%mf_getuniquefileref();
proc http method='GET' out=&fname1 &oauth_bearer
url="&base_uri/identities/groups/&group/members?limit=10000";
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
Expand Down
7 changes: 3 additions & 4 deletions viya/mv_getgroups.sas
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -54,7 +53,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand All @@ -72,7 +71,7 @@ options noquotelenmax;

proc http method='GET' out=&fname1 &oauth_bearer
url="&base_uri/identities/groups?limit=10000";
headers
headers
%if &grant_type=authorization_code %then %do;
"Authorization"="Bearer &&&access_token_var"
%end;
Expand Down
7 changes: 3 additions & 4 deletions viya/mv_getrefreshtoken.sas
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@
@brief deprecated - replaced by mv_tokenauth.sas
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mv_tokenauth.sas
**/

%macro mv_getrefreshtoken(client_id=someclient
,client_secret=somesecret
,grant_type=authorization_code
Expand Down
3 changes: 1 addition & 2 deletions viya/mv_getusergroups.sas
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand Down
9 changes: 4 additions & 5 deletions viya/mv_getusers.sas
Original file line number Diff line number Diff line change
Expand Up @@ -34,21 +34,20 @@
creationTimeStamp char(24),
modifiedTimeStamp char(24),
state char(6)
@param access_token_var= The global macro variable to contain the access token
@param grant_type= valid values:
* password
* authorization_code
* detect - will check if access_token exists, if not will use sas_services if
* detect - will check if access_token exists, if not will use sas_services if
a SASStudioV session else authorization_code. Default option.
* sas_services - will use oauth_bearer=sas_services
@param outds= The library.dataset to be created that contains the list of groups
@version VIYA V.03.04
@author Allan Bowe
@source https://github.com/sasjs/core
@author Allan Bowe, source: https://github.com/sasjs/core
<h4> Dependencies </h4>
@li mp_abort.sas
Expand All @@ -72,7 +71,7 @@
%let &access_token_var=;
%end;
%put &sysmacroname: grant_type=&grant_type;
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
%mp_abort(iftrue=(&grant_type ne authorization_code and &grant_type ne password
and &grant_type ne sas_services
)
,mac=&sysmacroname
Expand Down
2 changes: 1 addition & 1 deletion viya/mv_jobexecute.sas
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Example with parameters:
%mv_jobexecute(path=/Public/folder
%mv_jobexecute(path=/Public/folder
,name=somejob
,paramstring=%str("macvarname":"macvarvalue","answer":42)
)
Expand Down
Loading

0 comments on commit 6f86ed6

Please sign in to comment.