Mercurial > repos > shellac > sam_consensus_v3
comparison env/lib/python3.9/site-packages/bioblend/galaxy/visual/__init__.py @ 0:4f3585e2f14b draft default tip
"planemo upload commit 60cee0fc7c0cda8592644e1aad72851dec82c959"
author | shellac |
---|---|
date | Mon, 22 Mar 2021 18:12:50 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4f3585e2f14b |
---|---|
1 """ | |
2 Contains possible interactions with the Galaxy visualization | |
3 """ | |
4 from bioblend.galaxy.client import Client | |
5 | |
6 | |
7 class VisualClient(Client): | |
8 | |
9 def __init__(self, galaxy_instance): | |
10 self.module = 'visualizations' | |
11 super().__init__(galaxy_instance) | |
12 | |
13 def get_visualizations(self): | |
14 """ | |
15 Get the list of all visualizations. | |
16 | |
17 :rtype: list | |
18 :return: A list of dicts with details on individual visualizations. | |
19 For example:: | |
20 | |
21 [{'dbkey': 'eschColi_K12', | |
22 'id': 'df1c7c96fc427c2d', | |
23 'title': 'AVTest1', | |
24 'type': 'trackster', | |
25 'url': '/api/visualizations/df1c7c96fc427c2d'}, | |
26 {'dbkey': 'mm9', | |
27 'id': 'a669f50f8bf55b02', | |
28 'title': 'Bam to Bigwig', | |
29 'type': 'trackster', | |
30 'url': '/api/visualizations/a669f50f8bf55b02'}] | |
31 """ | |
32 return self._get() | |
33 | |
34 def show_visualization(self, visual_id): | |
35 """ | |
36 Get details of a given visualization. | |
37 | |
38 :type visual_id: str | |
39 :param visual_id: Encoded visualization ID | |
40 | |
41 :rtype: dict | |
42 :return: A description of the given visualization. | |
43 For example:: | |
44 | |
45 {'annotation': None, | |
46 'dbkey': 'mm9', | |
47 'id': '18df9134ea75e49c', | |
48 'latest_revision': { ... }, | |
49 'model_class': 'Visualization', | |
50 'revisions': ['aa90649bb3ec7dcb', '20622bc6249c0c71'], | |
51 'slug': 'visualization-for-grant-1', | |
52 'title': 'Visualization For Grant', | |
53 'type': 'trackster', | |
54 'url': '/u/azaron/v/visualization-for-grant-1', | |
55 'user_id': '21e4aed91386ca8b'} | |
56 """ | |
57 return self._get(id=visual_id) |