| // Copyright 2015 The Vanadium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style |
| // license that can be found in the LICENSE file. |
| |
| package media_sharing |
| |
| type MediaSharing interface { |
| // DisplayURL will cause the server to display whatever media is at |
| // the given URL. The server will rely on the ContentType response |
| // header it gets when fetching the url to decide how to display |
| // the media. |
| DisplayUrl(url string) error |
| |
| // DisplayBytes will cause the server to display whatever media is |
| // sent in the stream. In the case of audio or movie media, the |
| // media should be played while the data is streaming. The mediaType |
| // can be used by the server to decide how to display the media. |
| DisplayBytes(mediaType string) stream<[]byte, _> error |
| } |