| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple 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 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 | 36 |
| 37 namespace blink { | 37 namespace blink { |
| 38 | 38 |
| 39 class HTTPHeaderMap; | 39 class HTTPHeaderMap; |
| 40 class ResourceResponse; | 40 class ResourceResponse; |
| 41 | 41 |
| 42 class CrossOriginPreflightResultCacheItem { | 42 class CrossOriginPreflightResultCacheItem { |
| 43 WTF_MAKE_NONCOPYABLE(CrossOriginPreflightResultCacheItem); | 43 WTF_MAKE_NONCOPYABLE(CrossOriginPreflightResultCacheItem); |
| 44 USING_FAST_MALLOC(CrossOriginPreflightResultCacheItem); | 44 USING_FAST_MALLOC(CrossOriginPreflightResultCacheItem); |
| 45 public: | 45 public: |
| 46 CrossOriginPreflightResultCacheItem(StoredCredentials credentials) | 46 explicit CrossOriginPreflightResultCacheItem(StoredCredentials credentials) |
| 47 : m_absoluteExpiryTime(0) | 47 : m_absoluteExpiryTime(0) |
| 48 , m_credentials(credentials) | 48 , m_credentials(credentials) |
| 49 { | 49 { |
| 50 } | 50 } |
| 51 | 51 |
| 52 bool parse(const ResourceResponse&, String& errorDescription); | 52 bool parse(const ResourceResponse&, String& errorDescription); |
| 53 bool allowsCrossOriginMethod(const String&, String& errorDescription) const; | 53 bool allowsCrossOriginMethod(const String&, String& errorDescription) const; |
| 54 bool allowsCrossOriginHeaders(const HTTPHeaderMap&, String& errorDescription
) const; | 54 bool allowsCrossOriginHeaders(const HTTPHeaderMap&, String& errorDescription
) const; |
| 55 bool allowsRequest(StoredCredentials, const String& method, const HTTPHeader
Map& requestHeaders) const; | 55 bool allowsRequest(StoredCredentials, const String& method, const HTTPHeader
Map& requestHeaders) const; |
| 56 | 56 |
| (...skipping 22 matching lines...) Expand all Loading... |
| 79 CrossOriginPreflightResultCache() { } | 79 CrossOriginPreflightResultCache() { } |
| 80 | 80 |
| 81 typedef HashMap<std::pair<String, KURL>, std::unique_ptr<CrossOriginPrefligh
tResultCacheItem>> CrossOriginPreflightResultHashMap; | 81 typedef HashMap<std::pair<String, KURL>, std::unique_ptr<CrossOriginPrefligh
tResultCacheItem>> CrossOriginPreflightResultHashMap; |
| 82 | 82 |
| 83 CrossOriginPreflightResultHashMap m_preflightHashMap; | 83 CrossOriginPreflightResultHashMap m_preflightHashMap; |
| 84 }; | 84 }; |
| 85 | 85 |
| 86 } // namespace blink | 86 } // namespace blink |
| 87 | 87 |
| 88 #endif | 88 #endif |
| OLD | NEW |