AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Thema durchsuchen
Ansicht
Themen-Optionen

RegEx via API?

Ein Thema von himitsu · begonnen am 1. Mär 2010 · letzter Beitrag vom 1. Mär 2010
Antwort Antwort
Benutzerbild von himitsu
himitsu

Registriert seit: 11. Okt 2003
Ort: Elbflorenz
43.136 Beiträge
 
Delphi 12 Athens
 
#1

RegEx via API?

  Alt 1. Mär 2010, 11:31
Ich bin grad in der Unit NSAPI.pas über etwas etwas gestolpert.

Mich hatte eigentlich nur mal interessiert, ob Delphi da auch etwas dabei hat, bzw. ob man da irgendwo sowas findet, denn immerhin bietet doch die IDE in der Suchfunktion auch etwas?

Delphi-Quellcode:
{*******************************************************}
{                                                       }
{                Delphi Runtime Library                 }
{                                                       }
{ Copyright(c) 1995-2010 Embarcadero Technologies, Inc. }
{                                                       }
{*******************************************************}

{*******************************************************}
{       Structure definitions and prototypes for the    }
{       Netscape Internet Server API (NSAPI)            }
{*******************************************************}

{*****************************************************************************}
{* From shexp.h                                                               }
{*****************************************************************************}
{
  Defines and prototypes for shell exp. match routines


  This routine will match a string with a shell expression. The expressions
  accepted are based loosely on the expressions accepted by zsh.

  o * matches anything
  o ? matches one character
  o \ will escape a special character
  o $ matches the end of the string
  o [abc] matches one occurence of a, b, or c. The only character that needs
          to be escaped in this is ], all others are not special.
  o [a-z] matches any character between a and z
  o [^az] matches any character except a or z
  o ~ followed by another shell expression will remove any pattern
      matching the shell expression from the match list
  o (foo|bar) will match either the substring foo, or the substring bar.
              These can be shell expressions as well.

  The public interface to these routines is documented below.
}


{* --------------------------- Public routines ---------------------------- *}

{
  shexp_valid takes a shell expression exp as input. It returns:

  NON_SXP      if exp is a standard string
  INVALID_SXP  if exp is a shell expression, but invalid
  VALID_SXP    if exp is a valid shell expression
}


const
   NON_SXP = -1;
   INVALID_SXP = -2;
   VALID_SXP = 1;

{* and generic shexp/regexp versions *}
   NON_WILDPAT = NON_SXP;
   INVALID_WILDPAT = INVALID_SXP;
   VALID_WILDPAT = VALID_SXP;

{* and regexp versions *}
   NON_REGEXP = NON_SXP;
   INVALID_REGEXP = INVALID_SXP;
   VALID_REGEXP = VALID_SXP;

function shexp_valid(exp: PAnsiChar): Integer; cdecl;

{
  shexp_match

  Takes a prevalidated shell expression exp, and a string str.

  Returns 0 on match and 1 on non-match.
}

function shexp_match(str, exp: PAnsiChar): Integer; cdecl;

{
  shexp_cmp

  Same as above, but validates the exp first. 0 on match, 1 on non-match,
  -1 on invalid exp. shexp_casecmp does the same thing but is case
  insensitive.
}

function shexp_cmp(str, exp: PAnsiChar): Integer; cdecl;
function shexp_casecmp(str, exp: PAnsiChar): Integer; cdecl;
Dazu noch was Kleines von MS:
http://support.microsoft.com/kb/274204/de
http://support.microsoft.com/?scid=kb%3Ben-us%3B274204

Sooo, nun hab ich hier auf'm Rechner natürlich keine ns-httpd20.dll gefunden, in welcher sich dieses verstecken soll.

Täucht das nun oder ist dieses NSAPI (Netscape Server Application Programming Interface) nur in einem ServerOS vorhanden, bzw. nur wenn z.B. ein Sun Java System Web Server oder Zeus Web Server installiert ist?

Hab jedenfalls nicht viele Informationen gefunden, nur daß eben seit 'ner Weile, die oben genannten Serversysteme, diese API implementiert haben.
http://docs.sun.com/app/docs/doc/820...kc?l=de&a=view
Garbage Collector ... Delphianer erzeugen keinen Müll, also brauchen sie auch keinen Müllsucher.
my Delphi wish list : BugReports/FeatureRequests
  Mit Zitat antworten Zitat
Astat

Registriert seit: 2. Dez 2009
Ort: München
320 Beiträge
 
Lazarus
 
#2

Re: RegEx via API?

  Alt 1. Mär 2010, 18:16
Zitat von himitsu:
.. keine ns-httpd20.dll gefunden, in welcher sich dieses verstecken soll.
Hallo himitsu, habe W2K, W2K3, W2K8 alles Serversysteme, insgesammt 5 Rechner,
manche "nackig" manche mit Appache und JRE SDK nach

httpd20.dll, httpd20, httpd durchsucht, nicht ein Treffer.

Ein System mit Tomcat hab ich leider nicht im Zugriff.

lg. Astat
Lanthan Astat
06810110811210410503210511511603209711003210010110 9032084097103
03211611111604403209711003210010110903210010510103 2108101116122
11610103209010110510810103206711110010103210511003 2068101108112
10410503210310111509910411410510109810111003211910 5114100046
  Mit Zitat antworten Zitat
Benutzerbild von himitsu
himitsu

Registriert seit: 11. Okt 2003
Ort: Elbflorenz
43.136 Beiträge
 
Delphi 12 Athens
 
#3

Re: RegEx via API?

  Alt 1. Mär 2010, 19:19
Danke erstmal.

Die 20 scheint die Version 2.0 zu sein, also ns-httpd*.dll, aber es wäre natürlich zu schön gewesen, wenn da schon was im in Windows vorhanden wäre.

Wobei ... im .Net-Framewörk soll ja was drinnen sein, aber das bringt bei einem nativen Programm nicht viel.
Garbage Collector ... Delphianer erzeugen keinen Müll, also brauchen sie auch keinen Müllsucher.
my Delphi wish list : BugReports/FeatureRequests
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 02:33 Uhr.
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz