#include "src/objects/option-utils.h"
#include "src/numbers/conversions.h"
#include "src/objects/objects-inl.h"
namespace v8 {
namespace internal {
MaybeHandle<JSReceiver> GetOptionsObject(Isolate* isolate,
Handle<Object> options,
const char* method_name) { … }
MaybeHandle<JSReceiver> CoerceOptionsToObject(Isolate* isolate,
Handle<Object> options,
const char* method_name) { … }
Maybe<bool> GetStringOption(Isolate* isolate, Handle<JSReceiver> options,
const char* property,
const std::vector<const char*>& values,
const char* method_name,
std::unique_ptr<char[]>* result) { … }
V8_WARN_UNUSED_RESULT Maybe<bool> GetBoolOption(Isolate* isolate,
Handle<JSReceiver> options,
const char* property,
const char* method_name,
bool* result) { … }
Maybe<int> DefaultNumberOption(Isolate* isolate, Handle<Object> value, int min,
int max, int fallback, Handle<String> property) { … }
Maybe<int> GetNumberOption(Isolate* isolate, Handle<JSReceiver> options,
Handle<String> property, int min, int max,
int fallback) { … }
Maybe<double> GetNumberOptionAsDouble(Isolate* isolate,
Handle<JSReceiver> options,
Handle<String> property,
double default_value) { … }
}
}