Impala
Impalaistheopensource,nativeanalyticdatabaseforApacheHadoop.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
redactor.h
Go to the documentation of this file.
1 // Copyright 2015 Cloudera Inc.
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 //
18 //
21 
22 #ifndef IMPALA_UTIL_REDACTOR_H
23 #define IMPALA_UTIL_REDACTOR_H
24 
25 #include <string>
26 
27 namespace impala {
28 
33 //
51 //
54 std::string SetRedactionRulesFromFile(const std::string& rules_file_path);
55 
60 void Redact(std::string* string, bool* changed = NULL);
61 
63 inline std::string RedactCopy(const std::string& original) {
64  std::string temp(original);
65  Redact(&temp);
66  return temp;
67 }
68 
69 }
70 
71 #endif
std::string RedactCopy(const std::string &original)
Utility function to redacted a string without modifying the original.
Definition: redactor.h:63
void Redact(string *value, bool *changed)
Definition: redactor.cc:309
string SetRedactionRulesFromFile(const string &rules_file_path)
Definition: redactor.cc:260