• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/amule/wxWidgets-2.8.12/contrib/src/deprecated/

Lines Matching refs:wxExpr

3 // Purpose:     wxExpr
115 wxExpr::wxExpr(const wxString& functor)
122 wxExpr *pfunctor = new wxExpr(wxExprWord, functor);
127 wxExpr::wxExpr(wxExprType the_type, const wxString& word_or_string)
152 wxExpr::wxExpr(wxExprType the_type, wxChar *word_or_string, bool allocate)
177 wxExpr::wxExpr(long the_integer)
185 wxExpr::wxExpr(double the_real)
193 wxExpr::wxExpr(wxList *the_list)
200 wxExpr *listExpr = new wxExpr(wxExprList);
205 wxExpr *expr = (wxExpr *)node->GetData();
214 wxExpr::~wxExpr(void)
235 wxExpr *expr = value.first;
238 wxExpr *expr1 = expr->next;
249 void wxExpr::Append(wxExpr *expr)
259 void wxExpr::Insert(wxExpr *expr)
268 wxExpr *wxExpr::Copy(void) const
284 return new wxExpr(value.integer);
286 return new wxExpr(value.real);
288 return new wxExpr(wxExprString, wxString(value.string));
290 return new wxExpr(wxExprWord, wxString(value.word));
293 wxExpr *expr = value.first;
294 wxExpr *new_list = new wxExpr(wxExprList);
297 wxExpr *expr2 = expr->Copy();
310 // Get the wxExpr (containing (= wxExpr Value) form) for the given word
312 wxExpr *wxExpr::GetAttributeValueNode(const wxString& word) const // Use only for a clause or list
317 wxExpr *expr = value.first;
322 wxExpr *firstNode = expr->value.first;
325 wxExpr *secondNode = firstNode->next;
338 // Get the value (in wxExpr form) for the given word or string, assuming
340 wxExpr *wxExpr::AttributeValue(const wxString& word) const // Use only for a clause or list
345 wxExpr *attExpr = GetAttributeValueNode(word);
351 wxString wxExpr::Functor(void) const // Use only for a clause
362 bool wxExpr::IsFunctor(const wxString& f) const // Use only for a clause
372 wxExpr *wxExpr::Arg(wxExprType theType, int arg) const
374 wxExpr *expr = value.first;
387 wxExpr *wxExpr::Nth(int arg) const
392 wxExpr *expr = value.first;
406 int wxExpr::Number(void) const
412 wxExpr *expr = value.first;
421 void wxExpr::DeleteAttributeValue(const wxString& attribute)
426 wxExpr *expr = value.first;
427 wxExpr *lastExpr = this;
432 wxExpr *firstNode = expr->value.first;
435 wxExpr *secondNode = firstNode->next;
439 wxExpr *nextExpr = expr->next;
457 void wxExpr::AddAttributeValue(const wxString& attribute, wxExpr *val)
461 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
468 wxExpr *patt = new wxExpr(wxExprWord, attribute);
469 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
471 wxExpr *listExpr = new wxExpr(wxExprList);
480 void wxExpr::AddAttributeValue(const wxString& attribute, long val)
484 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
491 wxExpr *patt = new wxExpr(wxExprWord, attribute);
492 wxExpr *pval = new wxExpr(val);
493 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
495 wxExpr *listExpr = new wxExpr(wxExprList);
504 void wxExpr::AddAttributeValue(const wxString& attribute, double val)
508 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
513 wxExpr *patt = new wxExpr(wxExprWord, attribute);
514 wxExpr *pval = new wxExpr(val);
515 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
517 wxExpr *listExpr = new wxExpr(wxExprList);
526 void wxExpr::AddAttributeValueString(const wxString& attribute, const wxString& val)
530 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
536 wxExpr *patt = new wxExpr(wxExprWord, attribute);
537 wxExpr *pval = new wxExpr(wxExprString, val);
538 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
540 wxExpr *listExpr = new wxExpr(wxExprList);
549 void wxExpr::AddAttributeValueWord(const wxString& attribute, const wxString& val)
553 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
559 wxExpr *patt = new wxExpr(wxExprWord, attribute);
560 wxExpr *pval = new wxExpr(wxExprWord, val);
561 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
563 wxExpr *listExpr = new wxExpr(wxExprList);
572 void wxExpr::AddAttributeValue(const wxString& attribute, wxList *val)
576 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
584 wxExpr *patt = new wxExpr(wxExprWord, attribute);
585 wxExpr *pval = new wxExpr(val);
586 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
588 wxExpr *listExpr = new wxExpr(wxExprList);
597 void wxExpr::AddAttributeValueStringList(const wxString& attribute, wxList *string_list)
601 // cout << "Error! tried to add an attribute-value pair to a nonlist wxExpr expression\n";
609 // First make a list of wxExpr strings
610 wxExpr *listExpr = new wxExpr(wxExprList);
615 wxExpr *expr = new wxExpr(wxExprString, wxString(string));
621 wxExpr *patt = new wxExpr(wxExprWord, attribute);
622 wxExpr *pequals = new wxExpr(wxExprWord, wxT("="));
624 wxExpr *listExpr2 = new wxExpr(wxExprList);
633 bool wxExpr::GetAttributeValue(const wxString& att, int& var) const
635 wxExpr *expr = AttributeValue(att);
646 bool wxExpr::GetAttributeValue(const wxString& att, long& var) const
648 wxExpr *expr = AttributeValue(att);
659 bool wxExpr::GetAttributeValue(const wxString& att, float& var) const
661 wxExpr *expr = AttributeValue(att);
671 bool wxExpr::GetAttributeValue(const wxString& att, double& var) const
673 wxExpr *expr = AttributeValue(att);
683 bool wxExpr::GetAttributeValue(const wxString& att, wxString& var) const // Word OR string -> string
685 wxExpr *expr = AttributeValue(att);
700 bool wxExpr::GetAttributeValue(const wxString& att, wxExpr **var) const
702 wxExpr *expr = AttributeValue(att);
712 bool wxExpr::GetAttributeValueStringList(const wxString& att, wxList *var) const
714 wxExpr *expr = AttributeValue(att);
717 wxExpr *string_expr = expr->value.first;
732 void wxExpr::AssignAttributeValue(wxChar *att, wxChar **var) const
743 void wxExpr::WriteClause(FILE* stream) // Write this expression as a top-level clause
748 wxExpr *node = value.first;
769 void wxExpr::WriteExpr(FILE* stream) // Write as any other subexpression
846 wxExpr *expr = value.first;
850 wxExpr *arg1 = expr->next;
851 wxExpr *arg2 = arg1->next;
876 * wxExpr 'database' (list of expressions)
916 wxExpr *wxExprDatabase::FindClause(long id) // Find a term based on an integer id attribute
919 wxExpr *found = NULL;
922 wxExpr *term = (wxExpr *)position->GetData();
926 wxExpr *value = term->AttributeValue(wxT("id"));
936 wxExpr *wxExprDatabase::FindClause(const wxString& word, const wxString& val)
938 wxExpr *found = NULL;
941 wxExpr *term = (wxExpr *)position->GetData();
945 wxExpr *value = term->AttributeValue(word);
955 wxExpr *wxExprDatabase::FindClause(const wxString& word, long val)
957 wxExpr *found = NULL;
960 wxExpr *term = (wxExpr *)position->GetData();
964 wxExpr *value = term->AttributeValue(word);
973 wxExpr *wxExprDatabase::FindClause(const wxString& word, double val)
975 wxExpr *found = NULL;
978 wxExpr *term = (wxExpr *)position->GetData();
982 wxExpr *value = term->AttributeValue(word);
991 wxExpr *wxExprDatabase::FindClauseByFunctor(const wxString& functor)
993 wxExpr *found = NULL;
996 wxExpr *term = (wxExpr *)position->GetData();
1009 void wxExprDatabase::Append(wxExpr *clause)
1015 wxExpr *expr = clause->AttributeValue(attribute_to_hash);
1035 wxExpr *wxExprDatabase::HashFind(const wxString& functor, long value) const
1042 return (wxExpr *)hash_table->Get(key, value);
1045 wxExpr *wxExprDatabase::HashFind(const wxString& functor, const wxString& value) const
1048 return (wxExpr *)hash_table->Get(key, WXSTRINGCAST value);
1057 wxExpr *expr = (wxExpr *)node->GetData();
1119 wxExpr *expr = (wxExpr *)node->GetData();
1126 void add_expr(wxExpr * expr)
1132 bool wxExprIsFunctor(wxExpr *expr, const wxString& functor)
1136 wxExpr *first_expr = expr->value.first;
1155 wxExpr *x = new wxExpr(atol(str));
1166 wxExpr *x = new wxExpr(f);
1180 wxExpr *x = new wxExpr(d);
1195 wxExpr *x = new wxExpr(d);
1202 wxExpr *x = new wxExpr(wxExprWord, wxString(str, wxConvLibc).c_str());
1236 wxExpr *x = new wxExpr(wxExprString, s, false);
1242 wxExpr *car = (wxExpr *)ccar;
1243 wxExpr *cdr = (wxExpr *)ccdr;
1247 cdr = new wxExpr(wxExprList);
1256 wxExpr *expr = (wxExpr *)cexpr;