Navicat Premium 12.0.28激活(Navicat for MySQL. mac电脑直接使用,不用安装)

Navicat Premium 12.0.28激活(Navicat for MySQL. mac电脑直接使用,不用安装)

Navicat/* POLE – Portable library to access OLE Storage Copyright (C) 2002-2005 Ariya Hidayat <ariya@kde.org> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the authors nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include <iostream> #include <fstream> #include <stdlib.h> #include <stdio.h> #include <list> #include <string> #include “pole.h” void visit( int indent, POLE::Storage* storage, std::string path ) { std::list<std::string> entries; entries = storage->entries( path ); std::list<std::string>::iterator it; for( it = entries.begin(); it != entries.end(); ++it ) { std::string name = *it; std::string fullname = path + name; for( int j = 0; j < indent; j++ ) std::cout << ” “; POLE::Stream* ss = new POLE::Stream( storage, fullname ); std::cout << name; if( ss ) if( !ss->fail() )std::cout << ” (” << ss->size() << “)”; std::cout << std::endl; delete ss; if( storage->isDirectory( fullname ) ) visit( indent+1, storage, fullname + “/” ); } } void dump( POLE::Storage* storage, char* stream_name ) { POLE::Stream* stream = new POLE::Stream( storage, stream_name ); if( !stream ) return; if( stream->fail() ) return; // std::cout << “Size: ” << stream->size() << ” bytes” << std::endl; unsigned char buffer[16]; for( ;; ) { unsigned read = stream->read( buffer, sizeof( buffer ) ); for( unsigned i = 0; i < read; i++ ) printf( “%02x “, buffer[i] ); std::cout << ” “; for( unsigned i = 0; i < read; i++ ) printf( “%c”, ((buffer[i]>=32)&&(buffer[i]<128)) ? buffer[i] : ‘.’ ); std::cout << std::endl; if( read < sizeof( buffer ) ) break; } delete stream; } void extract( POLE::Storage* storage, char* stream_name, char* outfile ) { POLE::Stream* stream = new POLE::Stream( storage, stream_name ); if( !stream ) return; if( stream->fail() ) return; std::ofstream file; file.open( outfile, std::ios::binary|std::ios::out ); unsigned char buffer[16]; for( ;; ) { unsigned read = stream->read( buffer, sizeof( buffer ) ); file.write( (const char*)buffer, read ); if( read < sizeof( buffer ) ) break; } file.close(); delete stream; } int main(int argc, char *argv[]) { if( argc < 2 ) { std::cout << “Usage:” << std::endl; std::cout << argv[0] << ” filename [stream-name [output-file]]” << std::endl; return 0; } char* filename = argv[1]; char* streamname = (argc<3) ? 0 : argv[2]; char* outfile = (argc<4) ? 0 : argv[3]; POLE::Storage* storage = new POLE::Storage( filename ); storage->open(); if( storage->result() != POLE::Storage::Ok ) { std::cout << “Error on file ” << filename << std::endl; return 1; } if( !streamname ) visit( 0, storage, “/” ); else if( !outfile ) dump( storage, streamname ); else extract( storage, streamname, outfile ); delete storage; Navicat Premium 12.0.28激活 return 0; } 今天的文章
Navicat Premium 12.0.28激活(Navicat for MySQL. mac电脑直接使用,不用安装)分享到此就结束了,感谢您的阅读。

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。
如需转载请保留出处:https://bianchenghao.cn/119949.html

(0)
编程小号编程小号
上一篇 2024-07-10 11:11
下一篇 2024-07-10 11:30

相关推荐