| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2015 Google Inc. All rights reserved. | 2 * Copyright (C) 2015 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 public: | 44 public: |
| 45 MediaErrorState(); | 45 MediaErrorState(); |
| 46 void throwTypeError(const String& message); | 46 void throwTypeError(const String& message); |
| 47 void throwDOMException(const ExceptionCode&, const String& message); | 47 void throwDOMException(const ExceptionCode&, const String& message); |
| 48 void throwConstraintError(const String& message, const String& constraint); | 48 void throwConstraintError(const String& message, const String& constraint); |
| 49 void reset(); | 49 void reset(); |
| 50 | 50 |
| 51 bool hadException(); | 51 bool hadException(); |
| 52 bool canGenerateException(); | 52 bool canGenerateException(); |
| 53 void raiseException(ExceptionState&); | 53 void raiseException(ExceptionState&); |
| 54 String getErrorMessage(); |
| 54 NavigatorUserMediaError* createError(); | 55 NavigatorUserMediaError* createError(); |
| 55 private: | 56 private: |
| 56 enum ErrorType { | 57 enum ErrorType { |
| 57 NoError, | 58 NoError, |
| 58 TypeError, | 59 TypeError, |
| 59 DOMError, | 60 DOMError, |
| 60 ConstraintError | 61 ConstraintError |
| 61 }; | 62 }; |
| 62 ErrorType m_errorType; | 63 ErrorType m_errorType; |
| 63 String m_name; | 64 String m_name; |
| 64 ExceptionCode m_code; | 65 ExceptionCode m_code; |
| 65 String m_message; | 66 String m_message; |
| 66 String m_constraint; | 67 String m_constraint; |
| 67 }; | 68 }; |
| 68 | 69 |
| 69 } // namespace blink | 70 } // namespace blink |
| 70 | 71 |
| 71 #endif // MediaErrorState_h | 72 #endif // MediaErrorState_h |
| OLD | NEW |