2011-03-17 6 views
0

나는 pylibnet 라이브러리에 자신을 소개하고 있는데이 코드에서 가져온 상수를 어떻게 가져올 수 있는지 묻고 싶습니다.Pylibnet 상수

import libnet 
from libnet.constants import * 

도움말 (libnet)을 시도하지만 내 문제에 대한 답변이 없습니다.

감사합니다.

+0

동의 주시기 바랍니다 할 수있는 소음을 줄이기 위해 – theheadofabroom

답변

1

dir(libnet.constants)을 사용해 보셨습니까?

libnet.constants.__dict__도 작동합니다.

내 대답은 당신의 문제, 또는 g8ve 지침을 해결되는지 조금 당신이 더 도움이 필요하면

[x for x in libnet.constants.__dict__ if x[:2] != '__' and not callable(libnet.constants.__dict__[x])]