OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 19 matching lines...) Expand all Loading... |
30 | 30 |
31 #include "config.h" | 31 #include "config.h" |
32 #include "bindings/modules/v8/V8SQLResultSetRowList.h" | 32 #include "bindings/modules/v8/V8SQLResultSetRowList.h" |
33 | 33 |
34 #include "bindings/core/v8/ExceptionMessages.h" | 34 #include "bindings/core/v8/ExceptionMessages.h" |
35 #include "bindings/core/v8/ExceptionState.h" | 35 #include "bindings/core/v8/ExceptionState.h" |
36 #include "bindings/core/v8/V8Binding.h" | 36 #include "bindings/core/v8/V8Binding.h" |
37 #include "core/dom/ExceptionCode.h" | 37 #include "core/dom/ExceptionCode.h" |
38 #include "modules/webdatabase/SQLResultSetRowList.h" | 38 #include "modules/webdatabase/SQLResultSetRowList.h" |
39 | 39 |
40 namespace WebCore { | 40 namespace blink { |
41 | 41 |
42 void V8SQLResultSetRowList::itemMethodCustom(const v8::FunctionCallbackInfo<v8::
Value>& info) | 42 void V8SQLResultSetRowList::itemMethodCustom(const v8::FunctionCallbackInfo<v8::
Value>& info) |
43 { | 43 { |
44 ExceptionState exceptionState(ExceptionState::ExecutionContext, "item", "SQL
ResultSetRowList", info.Holder(), info.GetIsolate()); | 44 ExceptionState exceptionState(ExceptionState::ExecutionContext, "item", "SQL
ResultSetRowList", info.Holder(), info.GetIsolate()); |
45 if (!info.Length()) { | 45 if (!info.Length()) { |
46 exceptionState.throwDOMException(SyntaxError, ExceptionMessages::notEnou
ghArguments(1, 0)); | 46 exceptionState.throwDOMException(SyntaxError, ExceptionMessages::notEnou
ghArguments(1, 0)); |
47 exceptionState.throwIfNeeded(); | 47 exceptionState.throwIfNeeded(); |
48 return; | 48 return; |
49 } | 49 } |
50 | 50 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 default: | 83 default: |
84 ASSERT_NOT_REACHED(); | 84 ASSERT_NOT_REACHED(); |
85 } | 85 } |
86 | 86 |
87 item->ForceSet(v8String(info.GetIsolate(), rowList->columnNames()[i]), v
alue, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly)); | 87 item->ForceSet(v8String(info.GetIsolate(), rowList->columnNames()[i]), v
alue, static_cast<v8::PropertyAttribute>(v8::DontDelete | v8::ReadOnly)); |
88 } | 88 } |
89 | 89 |
90 v8SetReturnValue(info, item); | 90 v8SetReturnValue(info, item); |
91 } | 91 } |
92 | 92 |
93 } // namespace WebCore | 93 } // namespace blink |
OLD | NEW |