| // Copyright 2016 The Fuchsia Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| library fuchsia.media.playback; |
| |
| /// Models a problem preventing intended operation. |
| /// |
| /// A `Problem` is generally surfaced as part of a component's status, probably |
| /// as an optional field. Absence of a `Problem` means that nothing is preventing |
| /// intended operation. When a problem is exposed, the client can take action |
| /// automatically or present relevant UI. If a problem can be resolved by some |
| /// action, the client may take that action automatically or enlist the user |
| /// somehow in the resolution. In either case, the problem goes away when the |
| /// issue that caused it to be exposed is resolved. By design, there is no |
| /// general means of dismissing a problem. |
| struct Problem { |
| /// The type of problem. This is a string for extensibility. |
| string type; |
| |
| /// Type-dependent details. |
| string? details; |
| }; |
| |
| const string PROBLEM_INTERNAL = |
| "fuchsia.media.playback.Internal"; |
| const string PROBLEM_ASSET_NOT_FOUND = |
| "fuchsia.media.playback.AssetNotFound"; |
| const string PROBLEM_CONTAINER_NOT_SUPPORTED = |
| "fuchsia.media.playback.ContainerNotSupported"; |
| const string PROBLEM_AUDIO_ENCODING_NOT_SUPPORTED = |
| "fuchsia.media.playback.AudioEncodingNotSupported"; |
| const string PROBLEM_VIDEO_ENCODING_NOT_SUPPORTED = |
| "fuchsia.media.playback.VideoEncodingNotSupported"; |
| const string PROBLEM_CONNECTION_FAILED = |
| "fuchsia.media.playback.ConnectionFailed"; |