Code Monkey home page Code Monkey logo

ziher's Introduction

What is ziher? Find here.

ziher

python

C:\dev\ziher\ziher_mono\ziher\src\bazel-bin\test>dir f18ziherpy.pyd
 Volume in drive C has no label.
 Volume Serial Number is F0E2-A75E

 Directory of C:\dev\ziher\ziher_mono\ziher\src\bazel-bin\test

27. 08. 2022.  15:41            16.896 f18ziherpy.pyd
               1 File(s)         16.896 bytes
               0 Dir(s)  762.793.041.920 bytes free
C:\dev\ziher\ziher_mono\ziher\src\bazel-bin\test>dumpbin /dependents f18ziherpy.pyd

Dump of file f18ziherpy.pyd

File Type: DLL

  Image has the following dependencies:
    ziher.dll
    hello_py.dll
    python3.dll
    VCRUNTIME140.dll
    api-ms-win-crt-stdio-l1-1-0.dll
    api-ms-win-crt-runtime-l1-1-0.dll
    api-ms-win-crt-string-l1-1-0.dll
    KERNEL32.dll

  Summary

        1000 .data
        1000 .pdata
        2000 .rdata
        1000 .reloc
        2000 .text
C:\dev\ziher\ziher_mono\ziher\src\bazel-bin\test>dumpbin /exports f18ziherpy.pyd
Dump of file f18ziherpy.pyd
File Type: DLL
  Section contains the following exports for f18ziherpy.dll

    00000000 characteristics
    FFFFFFFF time date stamp
        0.00 version
           1 ordinal base
           2 number of functions
           2 number of names

    ordinal hint RVA      name

          1    0 00001720 PyInit_f18ziherpy = PyInit_f18ziherpy
          2    1 00001000 hello_py_ext_101 = hello_py_ext_101

Ziher from python

run parametri: MAIN - ime funkcije, 1 - init console, 1 - release console

>>> import f18ziherpy
>>> f18ziherpy.vminit();f18ziherpy.run("MAIN",1,1);f18ziherpy.run("MAIN",1,1);quit()

callback lamda funkcija

Definišemo lamda funkciju x+y+3. Poziv init console=1, release console=1 f18ziherpy.hash('ZIHER_TO_PY',1,1). Hash vraća python dict objekat napunjen unutar ziher kao hash varijabla.

python -c "callback = lambda x,y: x+y+3;import f18ziherpy;f18ziherpy.vminit();f18ziherpy.set_callback(callback);ret=f18ziherpy.hash('ZIHER_TO_PY',1,1);print(ret);quit()"

dva setovanja callback-a i dva hash poziva

python -c "callback = lambda x,y: x+y+3;import f18ziherpy;f18ziherpy.vminit();f18ziherpy.set_callback(callback);ret=f18ziherpy.hash('ZIHER_TO_PY',1,1);print(ret);callback2 = lambda x,y: x+y+23;f18ziherpy.set_callback(callback2);print(f18ziherpy.hash('ZIHER_TO_PY',1,1));quit()"

ziher's People

Contributors

hernad avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.