Lines Matching defs:itemList
102 void Options::CollectInputAbcFile(const std::vector<std::string> &itemList, const std::string &inputExtension)
104 std::string fileName = itemList[0];
105 // Split the fileInfo string to itemList by the delimiter ';'. If the element is empty, it will not be added to
106 // the itemList. The fileInfo string of the abc file only contains the file path and pkgName, so the index
112 if (itemList.size() > PKG_NAME_IDX && compilerOptions_.mergeAbc) {
113 src.pkgName = itemList[PKG_NAME_IDX];
118 void Options::CollectInputSourceFile(const std::vector<std::string> &itemList, const std::string &inputExtension)
120 std::string fileName = itemList[0];
121 std::string recordName = compilerOptions_.mergeAbc ? itemList[1] : "";
127 if (itemList[SCRIPT_KIND_IDX] == "script") {
129 } else if (itemList[SCRIPT_KIND_IDX] == "commonjs") {
136 src.sourcefile = itemList[SOURCE_FIEL_IDX];
138 src.pkgName = itemList[PKG_NAME_IDX];
141 if (itemList.size() == ITEM_COUNT_MERGE) {
142 src.isSharedModule = itemList[Is_SHARED_MODULE_IDX] == "true";
147 outputFiles_.insert({fileName, itemList[PKG_NAME_IDX]});
151 bool Options::CheckFilesValidity(const std::string &input, const std::vector<std::string> &itemList,
155 if ((compilerOptions_.mergeAbc && itemList.size() > ITEM_COUNT_MERGE) ||
156 (!compilerOptions_.mergeAbc && itemList.size() > ITEM_COUNT_NOT_MERGE) || itemList.empty()) {
160 << " items per line, but found " << itemList.size() << " items." << std::endl
186 std::vector<std::string> itemList = GetStringItems(line, LIST_ITEM_SEPERATOR);
187 if (!CheckFilesValidity(input, itemList, line)) {
190 if (IsAbcFile(itemList[0], inputExtension)) {
191 CollectInputAbcFile(itemList, inputExtension);
193 CollectInputSourceFile(itemList, inputExtension);
234 std::vector<std::string> itemList = GetStringItems(line, LIST_ITEM_SEPERATOR);
235 if (itemList.size() != cacheListItemCount) {
238 compilerOptions_.cacheFiles.insert({itemList[0], itemList[1]});