Guidance
指路人
g.yi.org
Upload / Forum Attachment / Reginald Rexx Programming Language Compiler User Forum Attachments and Pictures / 13400-Declare.rex

Register 
注册
Search 搜索
首页 
Home Home
Software
Upload

  
/* -----------------------------------------------------------------------------------
 * DEFINE: Define Structure, 
 * PUT:    Build Record using Variables
 * GET:    Extract Variables from Record 
 * -----------------------------------------------------------------------------------
 */
declare: PROCEDURE EXPOSE(allitems)  
PARSE ARG mode,strdef,strval
IF mode='DEFINE' THEN DO 
   IF strval="" THEN strval=";;"
   struct=''
   DO i=1 TO WORDS(strdef)
      struct=struct||"'"strval"'"WORD(strdef,i)
   END
   IF EXISTS("AllItems")=0 THEN allitems=""
   allitems=allitems||strdef" "
   RETURN SUBSTR(struct,LENGTH(strval)+3)   
END
IF mode='PUT' THEN DO 
   INTERPRET "record="strdef
   RETURN record
END 
IF mode='GET' THEN DO 
   INTERPRET "parse value strval with "strdef
   RETURN ""
END 
掌柜推荐
 
 
 
 
 
 
 
 
 
 
 
 
© Thu 2024-10-3  Guidance Laboratory Inc.
Email:webmaster1g.yi.org Hits:0 Last modified:2010-11-08 15:19:54