Skip to content

Instantly share code, notes, and snippets.

@mamund
Last active February 10, 2017 20:06
Show Gist options
  • Save mamund/5069d3d747754fa6de5865511005caae to your computer and use it in GitHub Desktop.
Save mamund/5069d3d747754fa6de5865511005caae to your computer and use it in GitHub Desktop.
stable ALPS descriptions for varying runtime messages
<alps>
<doc>ALPS search w/ varying network promises for the same named action</doc>
<!-- data -->
<descriptor id="text" type="semantic" />
<descriptor id="url" type="semantic" />
<!-- actions -->
<descriptor id="form" name="search" type="safe" rt="results">
<descriptor href="#text" name="value"/>
</descriptor>
<descriptor id="link" name="search" type="safe">
<descriptor href="#url" name="search-url"/>
</descriptor>
<descriptor id="save" name="search" type="unsafe">
<descriptor href="#url" name="results-url"/>
</descriptor>
<descriptor id="results">
<descriptor href="#text" name="results-content"/>
<descriptor href="#url" name="results-url"/>
</descriptor>
</alps>
<!-- home page with search link on it -->
<html>
<body>
<a href="..." name="search">Start Search</a>
</body>
</html>
<!-- search page with form on it -->
<html>
<body>
<form action="..." method="get" name="search">
<input name="value" />
<input type="submit" value="Search databsase"/>
</form>
</body>
</html>
<!-- results page with save form on it -->
<html>
<body>
<div name="results-content">
...
</div>
<form action="..." method="post" name="search">
<input type="hidden" name="results-url" />
<input type="submit" value="Save this result set"/>
</form>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment