2015-01-15 4 views
0

그래서 나는 filterVoClass은 문자열입니다 com.vo.ReleaseFilterVO로 설정되는 코드에서이 시점에서 내 Flex 어플리케이션이 flex 메소드로 클래스를 생성하는 방법은 무엇입니까?

var factory:ClassFactory = new ClassFactory(filterVOClass); 
filterVO = FilterVO(factory.newInstance()); 

이 코드가 있습니다. 이 코드는 웹 콘솔에서 추적 할 수 있으므로 다음 객체를 빌드합니다.

FilterVo 
    Object { 
     addByName: null, 
     addDate: null, 
     addDateRange: null, 
     andFilters: null, 
     artistId: 0, 
     artistName: null, 
     catalogNumber: null, 
     changeByName: null, 
     changeDate: null, 
     created: null, 
     depth: 2, 
     duplicateUPC: null, 
     exclusive: null, 
     exclusiveDateRange: null, 
     facets: null, 
     id: 0, 
     ingestionMethod: null, 
     labelId: 0, 
     labelManagerId: 0, 
     labelManagerName: null, 
     labelName: null, 
     name: null, 
     newReleaseDateRange: null, 
     orFilters: null, 
     page: 1, 
     perPage: 0, 
     publishDateRange: null, 
     queryString: null, 
     queryTermField: null, 
     queryTermValue: null, 
     showCounts: true, 
     sort: null, 
     sortField: null, 
     status: null, 
     supplierId: 0, 
     supplierName: null, 
     tier: 0, 
     title: null, 
     trackCount: 0, 
     trackName: null, 
     typeId: 0, 
     upc: null, 
     upcVerified: false, 
     updated: null 
    } 

난 그냥 내 응용 프로그램의 아무 곳이나 특정 클래스를 찾을 수없는, 내가 의미하는 네임 스페이스에서 아무것도 찾을 수 없습니다 이러한 개체의 호텔이오고 있었다.

다음 문서를 읽었는데 아직 어떤 일이 일어나고 있는지 잘 모르겠습니다.

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/core/ClassFactory.html

편집 : ReleaseFilterVO 여기에서 유래는,이이 파일에 정의 된 뷰를 정의했다.

<?xml version="1.0" encoding="utf-8"?> 
<LookupPage xmlns="com.admin.view.page.lookup.*" 
xmlns:mx="http://www.adobe.com/2006/mxml" 
xmlns:basic="com.framework.view.widget.basic.*" 
xmlns:formElements="com.framework.view.form.formElements.*" 
xmlns:vo1="com.framework.model.vo.*" 
filterVOClass="com.vo.ReleaseFilterVO" 
itemType="{ VOTypes.RELEASE }" 
label="Releases" 
rowHeight="32"> 
+0

filterVOClass는 어디에서 왔습니까? – null

+0

질문을 편집하여 질문의 데이터에 대한 참조를 추가합니다. – Xenology

+0

일부 속성에 대해 검색 작업 영역을 시도 했습니까? "newReleaseDateRange"검색을 시도하십시오. – Nemi

답변

0

실제 클래스 참조를 전달해보십시오. 팩토리의 작업은 미리 정의 된 객체로 속성을 초기화하는 동안 새 인스턴스를 만드는 것입니다.

var factory:ClassFactory = new ClassFactory(com.vo.ReleaseFilterVO); 
var instance:ReleaseFilterVO = ReleaseFilterVO(factory.newInstance()); 
관련 문제